Title: Infospica Headless API
Author: Infospica
Published: <strong>2026 年 3 月 24 日</strong>
Last modified: 2026 年 3 月 24 日

---

搜索插件

![](https://ps.w.org/infospica-headless-api/assets/icon-256x256.png?rev=3489831)

# Infospica Headless API

 作者：[Infospica](https://profiles.wordpress.org/icssubscriptions/)

[下载](https://downloads.wordpress.org/plugin/infospica-headless-api.1.0.0.zip)

 * [详情](https://cn.wordpress.org/plugins/infospica-headless-api/#description)
 * [评价](https://cn.wordpress.org/plugins/infospica-headless-api/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/infospica-headless-api/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/infospica-headless-api/#developers)

 [支持](https://wordpress.org/support/plugin/infospica-headless-api/)

## 描述

Infospica Headless API transforms WordPress into a secure and flexible headless 
CMS by providing a custom REST API namespace with full CRUD capabilities.

Instead of modifying the default WordPress REST API, this plugin creates an isolated
and configurable API layer designed specifically for secure and scalable headless
architectures.

### Ideal for

 * Headless WordPress (Next.js, Nuxt, React, Vue, Angular)
 * Mobile applications
 * SaaS platforms
 * Custom frontend integrations
 * API-driven architectures

### Key Features

 * Custom API namespace with version control
 * Full CRUD endpoints (GET, POST, PUT, PATCH, DELETE)
 * Supports:
    - Pages
    - Posts
    - Custom Post Types
 * Optional ACF field support (if ACF is active)
 * Authentication-aware read and write access
 * Capability-based write protection
 * Built-in pagination support (`?page` and `?per_page`)
 * Clean and intuitive admin settings UI
 * Clean uninstall (removes plugin data and settings)

### Security Highlights

 * All API endpoints require authentication
 * Write operations require appropriate WordPress capabilities
 * CSRF protection enforced for cookie-based authentication (nonce validation)
 * Sensitive user data (such as email addresses) is not exposed
 * WooCommerce core pages are automatically excluded from API responses

### Authentication

All endpoints require authentication.

Supported authentication methods:

 * WordPress login cookies (browser/admin usage)
    - Write requests require `X-WP-Nonce` header or `_wpnonce` parameter
 * Application Passwords (recommended for external applications)
 * Any authentication method that properly sets the current user context

Write operations are additionally restricted by WordPress capabilities (e.g., `edit_posts`,`
delete_posts`).

### Available Endpoints

Base structure:

    ```
    /wp-json/{namespace}/{version}/
    ```

Example:

    ```
    /wp-json/my-api/v1/
    ```

#### Status

GET `/status`

#### Pages

GET `/pages`
 GET `/pages/{id}` POST `/pages` PUT `/pages/{id}` PATCH `/pages/{id}`
DELETE `/pages/{id}`

#### Posts

GET `/posts`
 GET `/posts/{id}` POST `/posts` PUT `/posts/{id}` PATCH `/posts/{id}`
DELETE `/posts/{id}`

#### Custom Post Types

GET `/{post-type}`
 GET `/{post-type}/{id}` POST `/{post-type}` PUT `/{post-type}/{
id}` PATCH `/{post-type}/{id}` DELETE `/{post-type}/{id}`

### Pagination

All list endpoints support:

    ```
    ?page=1  
    &per_page=10 (maximum 50)
    ```

Example:

    ```
    /wp-json/my-api/v1/posts?page=2&per_page=5<h3>License</h3>
    ```

This plugin is licensed under GPLv2 or later.

## 屏幕截图

[⌊Plugin settings page in WordPress admin⌉⌊Plugin settings page in WordPress admin⌉[

Plugin settings page in WordPress admin

[⌊REST API endpoints overview with generated URLs⌉⌊REST API endpoints overview with
generated URLs⌉[

REST API endpoints overview with generated URLs

## 安装

 1. Upload the plugin to `/wp-content/plugins/infospica-headless-api/`
 2. Activate the plugin from the WordPress admin panel
 3. Navigate to **Infospica Headless API** in the admin menu
 4. Configure namespace, version, and enabled content types
 5. Save settings
 6. Use the generated endpoints in your frontend application

## 常见问题

### Does this replace the default WordPress REST API?

No. It creates a separate custom REST namespace. The default WordPress REST API 
remains unchanged.

### Is authentication required?

Yes.

All endpoints require authentication.
 Write operations additionally require proper
WordPress capabilities.

### Does it support ACF?

Yes.

Enable ACF support in settings to include custom fields in API responses (if ACF
is installed and active).

### Does it support WooCommerce?

WooCommerce core pages are automatically excluded.

Dedicated WooCommerce API support may be added in a future release.

### Does it support pagination?

Yes.

Use:

    ```
    ?page=1  
    &per_page=10
    ```

## 评价

此插件暂无评价。

## 贡献者及开发者

「Infospica Headless API」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ Infospica ](https://profiles.wordpress.org/icssubscriptions/)
 *   [ pushpasharmila ](https://profiles.wordpress.org/pushpasharmila/)

[帮助将「Infospica Headless API」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/infospica-headless-api)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/infospica-headless-api/)，
查看[SVN仓库](https://plugins.svn.wordpress.org/infospica-headless-api/)，或通过
[RSS](https://plugins.trac.wordpress.org/log/infospica-headless-api/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/infospica-headless-api/)。

## 更新日志

#### 1.0.0

 * Initial stable release
 * Custom namespace-based REST API
 * Full CRUD support
 * CPT support
 * ACF integration
 * Pagination support
 * Admin UI

## 额外信息

 *  版本 **1.0.0**
 *  最后更新：**3 月前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 6.0 或更高版本 **
 *  已测试的最高版本为 **6.9.4**
 *  PHP 版本 ** 7.4 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/infospica-headless-api/)
 * 标签
 * [acf](https://cn.wordpress.org/plugins/tags/acf/)[custom api](https://cn.wordpress.org/plugins/tags/custom-api/)
   [headless](https://cn.wordpress.org/plugins/tags/headless/)[headless cms](https://cn.wordpress.org/plugins/tags/headless-cms/)
   [rest-api](https://cn.wordpress.org/plugins/tags/rest-api/)
 *  [高级视图](https://cn.wordpress.org/plugins/infospica-headless-api/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/infospica-headless-api/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/infospica-headless-api/reviews/)

## 贡献者

 *   [ Infospica ](https://profiles.wordpress.org/icssubscriptions/)
 *   [ pushpasharmila ](https://profiles.wordpress.org/pushpasharmila/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/infospica-headless-api/)