WordPress Integration Guide

Last updated:

Overview

The WordPress integration allows you to publish articles directly from tryMarketr to your WordPress site using the WordPress REST API. This works with both self-hosted WordPress sites and WordPress.com.

Prerequisites

  • WordPress 5.6 or higher
  • WordPress REST API enabled (enabled by default)
  • User account with publishing permissions
  • Application Passwords plugin (built-in for WP 5.6+)

Setup Guide

Step 1: Generate Application Password

  1. Log into your WordPress admin dashboard
  2. Navigate to Users → Profile (or Users → Your Profile)
  3. Scroll down to the Application Passwords section
  4. Enter a name for the application: tryMarketr
  5. Click Add New Application Password
  6. Copy the generated password immediately (format: xxxx xxxx xxxx xxxx xxxx xxxx)

Important

The Application Password is only shown once. Save it securely. You cannot retrieve it later.

Step 2: Create Integration in tryMarketr

  1. In tryMarketr, navigate to Integrations
  2. Click Add Integration
  3. Enter a display name (e.g., "My WordPress Blog")
  4. Select WordPress as the platform
  5. Fill in the required fields:
    • WordPress Site URL: Your site URL (e.g., https://myblog.com)
    • Username: Your WordPress username
    • Application Password: The password from Step 1
  6. Click Create Integration
  7. Click Test Connection to verify the setup

Step 3: Verify Configuration

After creating the integration, test the connection to ensure everything is configured correctly. A successful test will show a green "Healthy" status indicator.

API Reference

Authentication

tryMarketr uses HTTP Basic Authentication with your WordPress username and Application Password.

Authorization: Basic base64(username:application_password)

API Endpoints Used

Validate Credentials

GET /wp-json/wp/v2/users/me

Verifies authentication and retrieves user information.

Create Post

POST /wp-json/wp/v2/posts

Publishes a new article to WordPress.

Update Post

POST /wp-json/wp/v2/posts/{id}

Updates an existing published article.

Delete Post

DELETE /wp-json/wp/v2/posts/{id}

Removes an article from WordPress.

Required Permissions

  • Create posts (Author role or higher)
  • Edit posts
  • Delete posts
  • Publish posts

Troubleshooting

Error: "REST API is not enabled"

The WordPress REST API is disabled on your site.

Solution: Check with your hosting provider or ensure no security plugin is blocking the REST API. The REST API should be accessible at /wp-json/wp/v2/.

Error: "Invalid username or password"

Authentication credentials are incorrect.

Solution: Verify your username is correct and regenerate the Application Password. Ensure there are no extra spaces when copying the password.

Error: "403 Forbidden"

Your user account lacks publishing permissions.

Solution: Ensure your WordPress user has at least Author role. Contributor and Subscriber roles cannot publish posts.

Error: "Application Passwords not available"

Your WordPress site doesn't support Application Passwords.

Solution: Update to WordPress 5.6 or higher. If using an older version, install the Application Passwords plugin.

Self-hosted vs WordPress.com

Configuration differs slightly between self-hosted and WordPress.com sites.

Self-hosted: Use your site URL (e.g., https://myblog.com)

WordPress.com: Use your WordPress.com URL (e.g., https://myblog.wordpress.com)

Advanced Configuration

Custom Post Status

By default, articles are published immediately. You can modify the post status in your WordPress settings to use draft or pending review workflows.

Featured Images

Hero images from tryMarketr are automatically set as WordPress featured images when publishing.

Analytics Tracking

tryMarketr automatically injects a tracking pixel into published content for analytics. This appears as a 1x1 transparent image at the end of your post content.