Automattic Publicize API

The publicize API from Automattic — 15 operation(s) for publicize.

Operations 24

GET /wpcom/v2/sites/{wpcom_site}/publicize/connection-test-results GET /wpcom/v2/sites/{wpcom_site}/publicize/connection-test-results #
GET /wpcom/v2/sites/{wpcom_site}/publicize/connections GET /wpcom/v2/sites/{wpcom_site}/publicize/connections #
POST /wpcom/v2/sites/{wpcom_site}/publicize/connections POST /wpcom/v2/sites/{wpcom_site}/publicize/connections #
POST /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} POST /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} #
PUT /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} PUT /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} #
PATCH /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} PATCH /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} #
DELETE /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} DELETE /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id} #
GET /wpcom/v2/sites/{wpcom_site}/publicize/keyring-result GET /wpcom/v2/sites/{wpcom_site}/publicize/keyring-result #
GET /wpcom/v2/sites/{wpcom_site}/publicize/message-templates/placeholders GET /wpcom/v2/sites/{wpcom_site}/publicize/message-templates/placeholders #
GET /wpcom/v2/sites/{wpcom_site}/publicize/published-actions GET /wpcom/v2/sites/{wpcom_site}/publicize/published-actions #
POST /wpcom/v2/sites/{wpcom_site}/publicize/render-messages POST /wpcom/v2/sites/{wpcom_site}/publicize/render-messages #
GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions #
POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions #
GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} #
POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} #
PUT /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} PUT /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} #
PATCH /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} PATCH /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} #
DELETE /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} DELETE /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id} #
GET /wpcom/v2/sites/{wpcom_site}/publicize/services GET /wpcom/v2/sites/{wpcom_site}/publicize/services #
POST /wpcom/v2/sites/{wpcom_site}/publicize/share-post/{postId} POST /wpcom/v2/sites/{wpcom_site}/publicize/share-post/{postId} #
GET /wpcom/v2/sites/{wpcom_site}/publicize/share-status GET /wpcom/v2/sites/{wpcom_site}/publicize/share-status #
POST /wpcom/v2/sites/{wpcom_site}/publicize/share-status/sync POST /wpcom/v2/sites/{wpcom_site}/publicize/share-status/sync #
GET /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/font-options GET /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/font-options #
POST /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/generate-token POST /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/generate-token #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/automattic-publicize-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

automattic-publicize-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: WordPress.com REST API — wpcom/v2 namespace Publicize API
  version: v2
  description: Derived by API Evangelist from the WordPress.com REST API route index published at https://public-api.wordpress.com/wpcom/v2/. Paths, HTTP methods, and parameter names/types/descriptions/defaults are taken verbatim from that index. Response schemas are not published in the route index, so successful responses are described but not schematised; the error envelope was observed live on public-api.wordpress.com.
  contact:
    name: Automattic
    url: https://developer.wordpress.com/docs/api/
  x-derived-from: https://public-api.wordpress.com/wpcom/v2/
  x-derived-by: API Evangelist enrichment pipeline
servers:
- url: https://public-api.wordpress.com
security:
- bearerAuth: []
tags:
- name: publicize
paths:
  /wpcom/v2/sites/{wpcom_site}/publicize/connection-test-results:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeConnectionTestResults
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/connection-test-results
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/connections:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeConnections
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/connections
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: test_connections
        in: query
        required: false
        schema:
          type: boolean
        description: Whether to test connections.
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeConnections
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/connections
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                keyring_connection_ID:
                  type: integer
                  description: Keyring connection ID.
                external_user_ID:
                  type: string
                  description: External User Id - in case of services like Facebook.
                shared:
                  type: boolean
                  description: Whether the connection is shared with other users.
              required:
              - keyring_connection_ID
  /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id}:
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeConnectionsbyConnectionId
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: connection_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                shared:
                  type: boolean
                  description: Whether the connection is shared with other users.
    put:
      operationId: putWpcomV2SitesbyWpcomSitePublicizeConnectionsbyConnectionId
      summary: PUT /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: connection_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                shared:
                  type: boolean
                  description: Whether the connection is shared with other users.
    patch:
      operationId: patchWpcomV2SitesbyWpcomSitePublicizeConnectionsbyConnectionId
      summary: PATCH /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: connection_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                shared:
                  type: boolean
                  description: Whether the connection is shared with other users.
    delete:
      operationId: deleteWpcomV2SitesbyWpcomSitePublicizeConnectionsbyConnectionId
      summary: DELETE /wpcom/v2/sites/{wpcom_site}/publicize/connections/{connection_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: connection_id
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/keyring-result:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeKeyringResult
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/keyring-result
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: request_id
        in: query
        required: true
        schema:
          type: string
        description: ID of the connect request.
  /wpcom/v2/sites/{wpcom_site}/publicize/message-templates/placeholders:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeMessageTemplatesPlaceholders
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/message-templates/placeholders
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/published-actions:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizePublishedActions
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/published-actions
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/render-messages:
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeRenderMessages
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/render-messages
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                post_id:
                  type: integer
                  description: The ID of the post to render the messages for.
                items:
                  type: array
                  items:
                    type: object
                  description: List of per-connection render inputs.
                post_intent:
                  type: object
                  default: []
                  description: Edited post fields to use when rendering unsaved preview changes.
              required:
              - post_id
              - items
  /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeScheduledActions
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: post_id
        in: query
        required: false
        schema:
          type: integer
        description: The post ID to filter the items by.
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeScheduledActions
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                post_id:
                  type: integer
                connection_id:
                  type: integer
                message:
                  type: string
                share_date:
                  type: integer
                  description: Deprecated in favor of timestamp.
                timestamp:
                  type: integer
                  description: GMT/UTC Unix timestamp in seconds for the action.
              required:
              - post_id
              - connection_id
  /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeScheduledActionsbyActionId
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: action_id
        in: path
        required: true
        schema:
          type: string
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeScheduledActionsbyActionId
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: action_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                message:
                  type: string
                share_date:
                  type: integer
                  description: Deprecated in favor of timestamp.
                timestamp:
                  type: integer
                  description: GMT/UTC Unix timestamp in seconds for the action.
    put:
      operationId: putWpcomV2SitesbyWpcomSitePublicizeScheduledActionsbyActionId
      summary: PUT /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: action_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                message:
                  type: string
                share_date:
                  type: integer
                  description: Deprecated in favor of timestamp.
                timestamp:
                  type: integer
                  description: GMT/UTC Unix timestamp in seconds for the action.
    patch:
      operationId: patchWpcomV2SitesbyWpcomSitePublicizeScheduledActionsbyActionId
      summary: PATCH /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: action_id
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                message:
                  type: string
                share_date:
                  type: integer
                  description: Deprecated in favor of timestamp.
                timestamp:
                  type: integer
                  description: GMT/UTC Unix timestamp in seconds for the action.
    delete:
      operationId: deleteWpcomV2SitesbyWpcomSitePublicizeScheduledActionsbyActionId
      summary: DELETE /wpcom/v2/sites/{wpcom_site}/publicize/scheduled-actions/{action_id}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: action_id
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/services:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeServices
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/services
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/share-post/{postId}:
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeSharePostbyPostid
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/share-post/{postId}
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: postId
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                message:
                  type: string
                  description: The message to share.
                skipped_connections:
                  type: array
                  items: {}
                  description: Array of external connection IDs to skip sharing.
                async:
                  type: boolean
                  default: false
                  description: Whether to share the post asynchronously.
              required:
              - message
  /wpcom/v2/sites/{wpcom_site}/publicize/share-status:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeShareStatus
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/share-status
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      - name: post_id
        in: query
        required: true
        schema:
          type: integer
        description: The post ID to filter the items by.
  /wpcom/v2/sites/{wpcom_site}/publicize/share-status/sync:
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeShareStatusSync
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/share-status/sync
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                post_id:
                  type: integer
                  description: The post ID to update the data for.
                shares:
                  type: array
                  items:
                    type: object
                  description: The share status items.
              required:
              - post_id
              - shares
  /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/font-options:
    get:
      operationId: getWpcomV2SitesbyWpcomSitePublicizeSocialImageGeneratorFontOptions
      summary: GET /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/font-options
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
  /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/generate-token:
    post:
      operationId: postWpcomV2SitesbyWpcomSitePublicizeSocialImageGeneratorGenerateToken
      summary: POST /wpcom/v2/sites/{wpcom_site}/publicize/social-image-generator/generate-token
      tags:
      - publicize
      responses:
        '200':
          description: OK
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WPRestError'
      parameters:
      - name: wpcom_site
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                text:
                  type: string
                  description: The text to be used to generate the image.
                image_url:
                  description: The URL of the background image to use when generating the social image.
                template:
                  type: string
                  enum:
                  - highway
                  - dois
                  - fullscreen
                  - edge
                  description: The template slug.
                font:
                  type: string
                  description: The font slug.
              required:
              - text
components:
  schemas:
    WPRestError:
      type: object
      description: WordPress REST API error envelope (observed on public-api.wordpress.com).
      properties:
        code:
          type: string
          example: rest_unauthorized
        message:
          type: string
          example: Authentication required.
        data:
          type: object
          properties:
            status:
              type: integer
              example: 401
  securitySchemes:
    oauth2:
      type: oauth2
      description: WordPress.com OAuth 2.1, per https://public-api.wordpress.com/.well-known/openid-configuration
      flows:
        authorizationCode:
          authorizationUrl: https://public-api.wordpress.com/oauth2-1/authorize
          tokenUrl: https://public-api.wordpress.com/oauth2-1/token
          refreshUrl: https://public-api.wordpress.com/oauth2-1/token
          scopes:
            global: ''
            auth: ''
            openid: ''
            profile: ''
            email: ''
            users: ''
            sites: ''
            posts: ''
            comments: ''
            taxonomy: ''
            follow: ''
            sharing: ''
            freshly-pressed: ''
            notifications: ''
            insights: ''
            read: ''
            stats: ''
            media: ''
            menus: ''
            batch: ''
            videos: ''
    bearerAuth:
      type: http
      scheme: bearer