V2.0 Stable

WordPress Link Remover API

Programmatically remove internal and external links from WordPress posts, pages, categories, and tags. Advanced targeting with JWT authentication, rate limiting, and comprehensive link processing capabilities.

Remove Internal Links
Remove External Links
Target Specific URLs
Domain-Based Filtering
JWT Authentication
Rate Limiting
Usage Tracking
Media Tag Removal
Important Notice

This API requires WordPress JWT Authentication plugin to be installed and configured on your target WordPress site. The API now uses JWT tokens instead of username/password for enhanced security. Click here to generate your JWT token.

WordPress Link Remover API

The WordPress Link Remover API allows you to programmatically remove links from WordPress posts, pages, categories, and tags. You can remove internal links, external links, or target specific URLs and domains while preserving anchor text content.

Features

  • Content Type Support - Works with posts, pages, categories, and tags
  • Selective link removal - Remove internal, external, or both types of links
  • URL targeting - Remove links matching specific URLs (up to 10 URLs)
  • Domain targeting - Remove all links from specific domains (up to 10 domains)
  • Media tag removal - Remove img, video, audio, and other media tags
  • Smart anchor text handling - Preserve content while removing links
  • JWT Authentication - Enhanced security with token-based authentication
  • Rate limiting - Built-in protection with usage tracking
  • Comprehensive logging - Track API usage and success rates

Base URL

https://api.corenexis.com/wordpress/link-remover/

Request Method

  • POST only
  • Content-Type: application/json

Authentication

All API requests require authentication using Core Nexis credentials and JWT token for WordPress access. The API performs a 4-phase validation process to ensure security and proper authorization.

Required Credentials

You need three types of credentials to use this API:

Core Nexis API Credentials

WordPress JWT Token

4-Phase Validation Process

Phase Validation Error Response
Phase 1 Client Existence "Invalid client ID"
Phase 2 Account Status "Your account is suspended. Contact support."
"Your account has been expired at {date}. Contact support."
Phase 3 API Key Validation "API key invalid"
Phase 4 API Permission "WordPress Link Remover is not activated in your plan"

Getting JWT Token

Generate a JWT token from your WordPress site using the JWT Authentication plugin:

JWT Token Generation
curl -X POST https://yoursite.com/wp-json/jwt-auth/v1/token \
  -H "Content-Type: application/json" \
  -d '{
    "username": "your_username",
    "password": "your_password"
  }'
JWT Plugin Required

The JWT Authentication for WP REST API plugin must be installed and configured on your WordPress site. Use our JWT generator tool to create and verify your tokens.

Rate Limits & Pricing

API usage is subject to rate limits based on your subscription plan. All plans include comprehensive features with different usage allowances.

Basic Plan (free)

3 requests/minute
300 requests/day

Pro Plan

10 requests/minute
5,000 requests/day
Agency Plans Available

Custom enterprise and agency plans are available with higher limits and additional features. Contact our team for pricing and custom solutions.

Usage Tracking

Counted: Successful API calls and user input errors
Not Counted: Authentication failures and validation errors

Endpoints

Usage Examples

Here are comprehensive examples showing different ways to use the API with the new authentication system.

1. Remove All External Links

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "external"
  }'

2. Remove All Internal Links

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "internal"
  }'

3. Remove Both Internal and External Links

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "both"
  }'

4. Remove Specific URL

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "both",
    "matching_url": "https://badsite.com/spam-link"
  }'

5. Remove Multiple Specific URLs

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "external",
    "matching_url": [
      "https://badsite1.com/spam",
      "https://badsite2.com/unwanted",
      "https://example.com/old-page"
    ]
  }'

6. Remove Links from Specific Domain

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "external",
    "matching_domain": "spamsite.com"
  }'

7. Remove Links from Multiple Domains

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "both",
    "matching_domain": [
      "badsite1.com",
      "spamsite.com",
      "unwanted-domain.net"
    ]
  }'

8. Combined: URLs and Domains

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/sample-post/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "both",
    "matching_url": [
      "https://example.com/old-page",
      "https://remove-this-link.com/page"
    ],
    "matching_domain": [
      "spamsite.com",
      "badsite.net"
    ]
  }'

9. Process Category Page

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/category/technology/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "external"
  }'

10. Process Tag Page

cURL Example
curl -X POST "https://api.corenexis.com/wordpress/link-remover/" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "99999",
    "api_key": "your_key",
    "post_url": "https://example.com/tag/wordpress/",
    "jwt_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...",
    "link_type": "internal"
  }'
Programming Language Examples

PHP Example

PHP Implementation
Authentication or validation error: Invalid client ID

JavaScript Example

JavaScript Implementation
const data = {
    client_id: '99999',
    api_key: 'your_key',
    post_url: 'https://example.com/sample-post/',
    jwt_token: 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...',
    link_type: 'both',
    matching_url: ['https://remove-this.com/page'],
    matching_domain: ['spamsite.com']
};

fetch('https://api.corenexis.com/wordpress/link-remover/', {
    method: 'POST',
    headers: {
        'Content-Type': 'application/json'
    },
    body: JSON.stringify(data)
})
.then(response => {
    if (response.status === 429) {
        throw new Error('Rate limit exceeded. Please try again later.');
    }
    return response.json();
})
.then(result => {
    if (result.status === 'success') {
        console.log('Success:', result);
        console.log(`Removed ${result.total_links_removed} links from content ID ${result.content_id}`);
    } else {
        console.error('Error:', result.error);
    }
})
.catch(error => {
    console.error('Request failed:', error);
});

Error Handling

The API uses standard HTTP status codes and provides detailed error messages for troubleshooting.

HTTP Status Codes

Status Code Error Type Description
400 Bad Request Missing required fields, invalid JSON, authentication failed, or invalid parameters
401 Unauthorized Invalid client credentials or API not activated in plan
404 Not Found Post/page/category/tag not found or unable to retrieve content
405 Method Not Allowed Only POST requests are allowed
429 Too Many Requests Rate limit exceeded (per-minute or daily limit)
500 Internal Server Error Server processing error or WordPress API issues

Common Error Messages

Error Message Description
"Invalid client ID" Client ID does not exist in the system
"Your account is suspended. Contact support." Account status is suspended
"Your account has been expired at {date}. Contact support." Account has expired on the specified date
"API key invalid" API key doesn't match the client account
"WordPress Link Remover is not activated in your plan" API not included in current subscription plan
"Too Many Requests - Rate limit exceeded" Per-minute rate limit exceeded
"Daily limit reached. Upgrade your plan or try tomorrow." Daily usage limit exceeded
"Homepage not allowed. Please provide a specific post or page URL." Homepage URLs are not supported
"Post/Page not found or unable to retrieve post information" Content not found or inaccessible
"Invalid link_type. Must be 'internal', 'external', or 'both'." Invalid value provided for link_type parameter

URL Restrictions

Allowed: Specific posts, pages, categories, tags
Not Allowed: Homepage, blog page, pagination, anchor URLs

Error Handling Best Practices

  • Always check HTTP status code before processing the response
  • Implement retry logic for server errors (5xx) but not for client errors (4xx)
  • Respect rate limits and implement backoff mechanisms for 429 responses
  • Validate JWT token expiry and refresh when necessary
  • Display meaningful error messages to your users
  • Log errors for debugging and monitoring purposes

Getting Started

Step 1: Sign Up for Core Nexis Account

Visit Corenexis API Platfrom to create an account and get your:

  • client_id
  • api_key

Step 2: Activate WordPress Link Remover API

Ensure the WordPress Link Remover API is included in your subscription plan. Contact support if you need to upgrade or activate the API.

Step 3: Install WordPress JWT Plugin

Install and configure the JWT Authentication for WP REST API plugin on your WordPress site.

Step 4: Generate JWT Token

Use our JWT Generator Tool to create and verify your WordPress authentication tokens.

Step 5: Start Making API Calls

Use the examples provided in this documentation to start removing links from your WordPress content.

Support & Contact

Getting Help

Email Support: [email protected]
Documentation: api.corenexis.com

Request API Access

To get your API credentials and activate the WordPress Link Remover API, please provide:

  • Your intended use case for the API
  • Expected monthly request volume
  • WordPress sites you plan to use it with
  • Preferred subscription plan (Basic, Starter, Pro, or Custom)
Changelog

Version 2.0 (Current)

Added JWT authentication system
Implemented comprehensive rate limiting
Added usage tracking and analytics
Enhanced security and validation
Multiple URL and domain targeting
Media tag removal functionality
Removed username/password authentication

Version 1.0

  • Basic link removal functionality
  • Support for posts, pages, categories, and tags
  • Internal and external link categorization
  • Simple authentication with WordPress credentials