The Inventory Presser dealership plugin was built with a feed-first mentality. Our software & services company feeds inventory updates and photos to hundreds of sites each day. Here’s how we fine-tune sites for efficient Vehicle Post Type updates using the WordPress REST API.

💡 All the usual methods of importing and updating post data will work, too. Inventory Presser vehicles are posts, and plugins like WP All Import can import flat files and populate post meta values.

If you want to build a WordPress REST API client to update vehicles, here’s what we do at Friday Systems…

Install and activate plugins

These essential plugins are required to connect and update the vehicle data.

The REST API provides remote access to the WordPress post object. We extend the REST endpoints for posts and attachments to provide finer control over meta fields on posts and terms.

PluginWhere to getWhat it is 
inventory-presser core dealership plugin. We plan to submit to soon, please use this link for now.
wp-api-manipulate-meta routes to the REST API to read, write, and delete post and term meta values separately from posts and terms.

Create a user and Application Password for authentication during updates

We create an administrator user account that will not be used by humans. Then, we generate an Application Password for that user.

  1. Needs capabilities to insert, update, and delete posts, media attachments, and taxonomy terms.
  2. Needs an Application Password generated to authenticate requests to the REST API.

💡 Can’t find Application Passwords on your users? WordFence disables Application Passwords by default.

📋 If you’re a Friday Systems customer, you can stop here. Send us the site URL, user name, & application password, and we can begin updating the inventory.

Send requests to /wp-json/wp/v2/inventory

Use the list of meta fields and an example vehicle post to build requests.

POST to insert a vehicle

Use Basic Auth to provide the user name and application password you created earlier during POST or DELETE requests.

GET a list of vehicles

Retrieve or update a single vehicle

POST to update a vehicle by post ID. GET to retrieve a vehicle by post ID.

GET a vehicle’s photos