During your XLink remote platform setup, you may run into various issues that make it seem impossible at first to get a platform link established. Most of these boil down to a handful of causes that we’ve outlined on this page, and are easy to fix.

Note: For easier debugging, XLink logs all errors that appear during API calls to /internal_data/xlink_errors. If you contact us, please make sure to include these error logs in your ticket.

1. API not found under URL or authentication failed

This is by far the most common error during setting up a platform link. As you notice from the error message itself, this can have two potential causes. Unfortunately, XLink cannot tell these apart, so you’ll likely need to check on both of them yourself.

2. API not found under URL

This error indicates that the remote platform URL you provided in the XLink platform settings cannot be resolved to the actual remote platform. This can for example happen if the URL you provided is invalid, using the wrong protocol (http vs https) or an invalid subdomain (www.yourdomain.com vs yourdomain.com as example). Please make sure that the provided URL matches exactly the URL that your remote platform is set to operate on. If it operates on multiple URLs, set it to the primary one.

A second cause for this can be that XLink was not able to automatically install the required remote platform plugin, or it was not activated properly. In this case, you may need to manually install it yourself and ensure that it is active. The plugin files for the remote installation can be found under /src/addons/ThemeHouse/[Add-On]/_remote, where Add-On is the specific add-on module that corresponds to your remote platform (for example XPress for WordPress or XWiki for MediaWiki).

At last, this may happen if the API of your remote platform was manually disabled. In this case, you will need to re-enable it.

3. Authentication failed

XLink uses IP comparison to ensure that all API calls are coming from the same server. In some environments, this authentication method will fail, as your server accesses the remote platform API through a proxy or firewall, which masks the URL and will result in a negative check. If whitelisting your server calls is not possible, you will be required to set up an API key instead.

To set up an API key, open up your XenForo configuration file (normally found under /src/config.php), and add the following line at the bottom:

$config['xpressAPIPassword'] = 'YOUR_API_PASSWORD'; 

You will need to replace the password inside the quotes with an alphanumeric pass of your choice. Any characters (including whitespace) outside A-Z and 0-9 will not work.

Once you’ve set up your API password on your XenForo installation, you will additionally need to configure it on your remote platform. This approach is the same for all remote platforms. Open your remote platform configuration file and paste the following line at the bottom:

define('XLINK_API_PASSWORD', 'YOUR_API_PASSWORD'); 

As above, you will need to replace the password inside the quotes with your previously chosen password.

Note: We do recommend to change the API password on a regular basis.

4. Request blocked by remote installation

This is the second most common error. This generally means, that XLinks API call was denied by the server or remote software. This can for example happen if an http password prompt is in place (such as a htpasswd file), or a firewall (or security plugin) aggressively blocks the calls.

  • Firewalls & security plugins - Security plugins such as WordFence restrict access to the API, thus preventing XLink from establishing a connection. Your security measure needs to be properly configured in order for XLink to be able to connect to your remote installation. As the specific configuration varies depending on method and server, we unfortunately cannot provide any further assistance with that.
  • Password protection - If your server is protected by a password (password prompt opens in the browser when you access your site), XLink won’t be able to connect to the API by default. Password protection can be passed into the URL, following the schema, allowing XLink to access the API as normal.
<protocol>://<user>:<password>@url.com

5. Remote platform error

This error indicates that something on your remote platform went wrong, and likely code execution was halted unexpectedly. You may retrieve more information by checking on the remote response in the XLink error log (logged to /internal_data/xlink_errors), and by checking your server error log.

Note: When contacting us about this issue, please make sure to include the error that was logged by your remote platform. Otherwise we will not be able to provide any assistance.

Did this answer your question?