WPGetAPI – Connect to external API's

外掛說明

WPGetAPI is the easiest way to connect WordPress with external API’s, allowing you to easily get (or send) data to/from 3rd party API’s and then display the returned data on your WordPress website using a shortcode or a template tag.

The API data can be output as either a JSON string or as a PHP array, allowing you to easily format the data. You could create tables or charts from the data plus many other possibilities.

WPGetAPI supports many authentication methods including OAuth 2.0 Authorization.

View the Demo

Live Demo – Connecting WordPress to External API

Major Features

  • Connect your website to REST API’s
  • No coding required
  • Unlimited API’s & endpoints
  • GET, POST & PUT requests
  • Output API data using a template tag or shortcode
  • Set query string, header & body parameters

Documentation

View the docs or jump to these articles below to get started:

Extending WPGetAPI

There are a number of paid plugins available that extend the features of the free plugin:

The Pro Plugin provides many extra features.

  • Caching of API calls
  • Base64 encoded authorization
  • Connect to API’s using XML format
  • Retrieve nested data in shortcode
  • Format as HTML in shortcode
  • Format as a number in shortcode
  • Dynamic variables the query string, endpoint, headers & body
  • Works with any theme

The OAuth 2.0 Authorization plugin allows authorization of your API through the OAuth 2.0 method.

  • Authorize any OAuth 2.0 API
  • Simple setup
  • Works with any theme

The WooCommerce Import plugin allows you to import items/products/listings from your API and create WooCommerce products from these items.

  • Import with click of a button
  • Run imports automatically at your chosen interval
  • Map API data to standard WooComemrce fields, custom fields, categories, attributes, tags
  • Import & upload images
  • Automatic deletion of old/expired products
  • Works with any theme

Translating WPGetAPI

You can translate WPGetAPI into your own language on translate.wordpress.org

Here is an article to help get started with translations

螢幕擷圖

  • The Setup screen where you can add your external API's
  • Once an external API has been added, a new page will be created to setup the API endpoints
  • A live demo of the output when debug mode is set to true
  • Raw output from an API
  • Output from an API formatted into HTML table

安裝方式

Requirements

  • WordPress version 4.0 and later
  • PHP 5.6, Tested with PHP 8.0
  • cURL

Usage

  1. Go to the WPGetAPI -> Setup menu to add your API’s.
  2. Once your API’s are saved, a new tab is created allowing you to add endpoints.
  3. Once your endpoints are saved, you can use the template tag or shortcode to connect to your API and view the data.

常見問題集

Where can I find docs?

All of our documentation can be found here.

Can I connect to any REST API?

Yes most likely. It will depend on the type of authentication your API is using. Please click the link to view the types of authentication and authorization that are available.

How do I cache API calls?

We support caching with our Pro Plugin

Can I use an XML based API?

We support XML with our Pro Plugin

Will you help me if I am having trouble?

Yes! Please contact us and we will get your API up and running.

How do I connect WordPress to an external API?

A good start is to visit our Quick Start Guide as well as the rest of our docs.

使用者評論

2022 年 5 月 27 日
If you want to integrate any API into your wordpress site, don't look further, WPGetAPI is amazing, simple to setup and configure. The support is amazing and the price is a no-brainer for the value you get. 10/10
2022 年 5 月 23 日
WPGetAPI plugins are excellent. They make connecting to external API so EASY! I would recommend WPGetAPI's plugins to anybody. The support is top class as well. I could not find a better solution for connecting to external APIs anywhere. I did the research and contacted several developers and plugin developers about their solutions and no one could beat WPGetAPI.
2022 年 5 月 18 日
After paying through the nose to another plugin provider, this was a breath of fresh air. Very straight forward, very helpful and no hidden fees! I can't say enough good stuff about this plugin and the support provided for the plugin. If you need an external API connection in your WP install turn key ready to go - this is it!
2022 年 5 月 15 日
The plugin works as advertised and is well-supported by the developer who took the time to answer my questions promptly and on the weekend, too! Highly recommended.
2022 年 3 月 8 日
As a newbie to APi integration this area daunted me when I spoke to some subcontractors they were quoting me $750 to $1000 to just pull the code through. This plug in does all that for you and as I only wanted a GET API this was free. A little nudging from the support team and I was up and running. Perfect service for a perfect app. Thanks Team
閱讀全部 9 則使用者評論

參與者及開發者

以下人員參與了開源軟體〈WPGetAPI – Connect to external API's〉的開發相關工作。

參與者

變更記錄

1.5.3 (2022-07-29)

  • Enhancement – add new request method PUT

1.5.2 (2022-07-06)

  • Enhancement – add new action to get response code. Required for OAuth 2.0 Authorization plugin.

1.5.1 (2022-07-06)

  • Enhancement – add new shortcode attributes for formatting HTML in Pro plugin.
  • Enhancement – minor styling tweaks.
  • Fix – very minor bug fixes.

1.5.0 (2022-06-27)

  • Fix – fully internationalize the plugin.

1.4.10 (2022-06-22)

  • Fix – add new filter ‘wpgetapi_json_response_body_before_decode’ in place of removing invalid characters from 1.4.8 as this was stripping out non-english values.

1.4.9 (2022-06-22)

  • Enhancement – rewrite some css to make endpoint page a bit nicer and add some more screenshots.

1.4.8 (2022-06-07)

  • Enhancement – remove invalid characters from JSON data that was causing a null return.

1.4.7 (2022-05-25)

  • Fix – change the redirect after saving to a javascript solution

1.4.6 (2022-05-24)

  • Enhancement – add new attribute ‘format’ within shortcode that allows formatting of a number in the Pro Plugin.

1.4.5 (2022-05-18)

  • Fix – error in admin-options file.

1.4.4 (2022-05-18)

  • Enhancement – add some better, and clearer help in the admin area. Tidy up some styling.
  • Fix – error displaying correct endpoint ID within admin area shortcode and template tag helpers. Happening when multiple endpoints added.

1.4.3 (2022-05-15)

  • Fix – body was not being set correctly.

1.4.2 (2022-05-13)

  • Enhancement – readme updates and plugin links within plugin page.

1.4.1 (2022-05-05)

  • Fix – new tab was not appearing on intitial save on setup page.
  • Enhancement – add new filter ‘wpgetapi_admin_pages’ to allow adding extra tabs.

1.4.0 (2022-03-17)

  • Fix – refactor the building of request args. Body was not working correctly.
  • Fix – change naming convention from Template Function to Template Tag within admin.
  • Enhancement – modify output of debug to show more info and to show whether or not shortcode is used.

1.3.4 (2022-03-17)

  • Enhancement – add ability to use headers and body variables in Pro Plugin.

1.3.3 (2022-03-03)

  • Enhancement – style the debug output to make it easier to understand and provide links to docs.

1.3.2 (2022-02-22)

  • Bug fix – change paramater value fields to textarea. This allows the proper use of JSON strings within these fields.

1.3.1 (2022-02-16)

  • Bug fix – error with class property name that was not allowing proper $args to be sent to remote request

1.3.0 (2022-02-08)

  • Fix – rewrite headers parameters section

1.2.3 (2021-12-14)

  • Enhancement – add ability for query_variables to be used in shortcode with the Pro Plugin

1.2.2 (2021-11-09)

  • Enhancement – add args to debug info. Will be useful for endpoint_variables in Pro Plugin

1.2.1 (2021-11-05)

  • Bug fixes with encrypting values

1.2.0 (2021-11-04)

  • Enhancement – add option to JSON encode body parameters
  • Enhancement – allow simple arrays to be sent in body

1.1.0 (2021-11-03)

  • Enhancement – reconfigure debug info
  • Bug fixes

1.0.2 (2021-11-02)

  • Bug fixes

1.0.1 (2021-11-02)

  • Bug fixes

1.0.0 (2021-10-27)

  • Initial Release