Linux 软件免费装
Banner图

Copypress Rest API

开发者 copypressdev
更新时间 2026年8月24日 23:28
PHP版本: 7.4 及以上
WordPress版本: 7.0
版权: GPL2
版权网址: 版权信息

标签

posts tags categories image upload REST API

下载

1.1 1.2 1.3 1.3.1

详情介绍:

The COPYPRESS REST API plugin extends the WordPress REST API with custom endpoints for managing posts, categories, tags, post types, and taxonomies. Features Endpoints
  1. /copypress-api/v1/login - Login with username and password to get a JWT token.
  2. Request Body:
  3. username (string): WordPress username
  4. password (string): WordPress password
  5. POST /copypress-api/v1/posts - Create a new post.
  6. Request Body:
  7. title (string): The title of the post.
  8. content (string): The content of the post.
  9. excerpt (string, optional): The excerpt of the post.
  10. category_main (string): The category taxonomy name.
  11. category (string): The category name or slug.
  12. tags_main (string, optional): The tags taxonomy name. Required only when tags are provided.
  13. tags (string, optional): Comma-separated list of tag names or slugs.
  14. image (string, optional): URL of an image to be set as the post's featured image.
  15. post_type (string, optional): The post type (default: post).
  16. author_id (int, optional): The ID of the post author (default: current user).
  17. post_status (string): Post publish status.
  18. Note: Tags are optional. If no tags are provided, tags_main can be empty and tag processing will be skipped.
  19. Response: Success message, HTTP status code, and created post object.
  20. PUT /copypress-api/v1/posts/{id} - Update an existing post.
  21. Request Body: Same as POST endpoint.
  22. Response: Success message, HTTP status code, and updated post object.
  23. DELETE /copypress-api/v1/posts/{id} - Delete a post.
  24. Response: Success message and HTTP status code.
  25. GET /copypress-api/v1/categories - Get all categories.
  26. Response: Category ID, name, and slug.
  27. GET /copypress-api/v1/tags - Get all tags.
  28. Response: Tag ID, name, and slug.
  29. GET /copypress-api/v1/post-types - Get all public post types.
  30. Response: Post type name and label.
  31. GET /copypress-api/v1/get-taxonomies/{post_type} - Get all taxonomies (categories and tags) associated with a specific post type.
  32. Response: List of categories (hierarchical taxonomies) and tags (non-hierarchical taxonomies).

安装:

  1. Download the plugin files.
  2. Upload the plugin folder to the /wp-content/plugins/ directory.
  3. Activate the plugin from the WordPress admin panel.

更新日志:

1.3.1 1.3 1.2 1.1 1.0