• Hi WP Community

    I have been developing a WP site for several months now and love it as a framework! Between searching, online videos, my host and plugin devs, I have always found great people to work with and get help from.

    I would like to be able to auto-publish my posts to two social networking websites, Gab.ai and Minds.com. Because these websites are still relatively new, small-scale and have limited API functionality there are currently no Plug-ins that I know of. It’s important to me to connect to these two sites because I know there is a high match between the theme of my site of the audience there, so I have decided to try and go commando and cook something up myself.

    Some research has allowed me to find these two resources:

    Small and cute social media CLI: https://github.com/DoumanAsh/fie
    and
    A wrapper for the gab.ai API https://github.com/PickledCatBrains/gab

    I am an absolute beginner with APIs so I’m not sure where to start. There are tons of materials and resources, but it feels like looking for a needle in haystack.

    The result I would like to achieve is to automatically publish the post title and post url to my profile on both websites.

    Any advice on how best to do that or how to get started much appreciated!

    Thanks for reading!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi, working with API is becoming more easy everyday with the wide adoption of RESTful style API, simply you will have an endpoint of the API (just a url) and you will have to make an http request of GET or POST type sending the parameters needed by the API endpoint which you find in their documentation.

    so Imagine this, the gab.ai will have an endpoint of
    gab.ai/new-post and its of type POST request
    first we need to authenticate ourselves to this endpoint and how to authenticate is found in their documentation most of API authentication is done via tokens, so when you signed up to that service they would have given you some credentials.

    Then we prepare the parameters needed by that API endpoint again look into their documentation to find out what is needed, then we make the request which in turn the endpoint will return to us with results like success or fail or missing stuff.

    With PHP use guzzle which will help you simplify the way you make requests and process results, with jQuery you can use get and post functions to also make requests.

    Working with APIs is fun once you make your first playground it will be easy to use another API.

    Thread Starter jpw3775

    (@jpw3775)

    Hi hyperionstudios

    Thank you for your answer, you have given me some good things to start working with and done a great job explaining it in such way that I could begin to understand it.

    Like my grand-father used to tell me “It’s easy when you know how..”.

    I’ll check back with any further questions and report on what I find.

    Thanks again,

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Auto publishing to 3rd party website with API/wrapper’ is closed to new replies.