Where possible, WishList Member allows you to create new data through the API by making a HTTP POST request to a specific resource.
Syntax
$response = $api->post($resource , $data);
Where:
- $resource – an API resource (i.e. /levels)
- $data – an associative array of data to pass to the API
Returns:
$response – string: can be either serialized PHP data, JSON or XML
Example
To create a new Membership Level using the API.
<?php $data = array('name' => 'Silver Level'); $response = $api->post('/levels', $data); ?>
Get more details are available on the WishList Member API.