Our customer Werk met Zin (Network of job coaches in Flanders) has a Wordpress site and uses CiviCRM to manage their relations and cases. On their Wordpress site they allow users to register for some events, which they solve with the civicrm event info and registration pages.
However, they also allow an individual to request the start of individual job coaching with a form. This should end up in CiviCRM as a special activity with the fields on the website form as custom data. And the Wordpress website is on another server, although that would not make such a big difference. Anyway, we (as in CiviCooP) developed a specific solution that takes the data from the Wordpress website on server A and sends it to CiviCRM on server B. The solution has a Wordpress part and a CiviCRM part.
This plugin can be found at https://wordpress.org/plugins/contact-form-7-civicrm-integration/ and works with the Contact Form 7 plugin. This plugin adds integration for CiviCRM to contact form 7. With this plugin it is possible to submit a contact form to an external CiviCRM. The plugin allows you to set the configuration items for the CiviCRM REST api (server, api key and site key)
Per contact form you could enable CiviCRM integration. The submission of the contact form is then submitted to the CiviCRM REST api. That is why you should also enter an CiviCRM entity and an CiviCRM action. The data in the form should then match the data for the api. E.g. if you push a first_name to the Contact api your field in the form should alsobe called first_name.
The CiviCRM extension has some stuff to create configuration items (activity types, option groups, option values, custom groups and custom fields are created or updated automatically by a scheduled job in the extension).
There is also an API WpCivi with action Submit. This API expects a parameter array with at least the element form_type and also expects to find a handler class with the name of this form_type in the extension. So currenty it can deal with a form which has form_type CoachingIndividual and the extension has the handler class CRM_Wpcivi_CoachingIndividual. This class extends the abstract class CRM_Wpcivi_ApiHandler and has to implement the method processParams. In this method the actual form data is processed. In our example, a contact is created and an activity of a specific type (with custom data) is created. If you would like to use this approach as a basis for your own needs you could remove the CoachingIndividual handler and add your own handler(s).
The extension can be found on GitHub: https://github.com/CiviCooP/be.werkmetzin.wpcivi and will not be in the CiviCRM extension directory as it is not a generic extension. But feel free to use as a basis for your own stuff!