create_update()
create_update(string $buffer_url, string $access_token, array|string $profile_ids, string $text = '', array $media = array(), boolean $attachment = true, boolean $shorten = false, boolean $now = false, boolean $top = false, integer $timeout = 15) : boolean|\WP_Error
Http post meta data to Buffer.
Schedule a social media update via Buffer.com's api. For more information see here https://buffer.com/developers/api/updates
Parameters
string | $buffer_url | Url of the Buffer.com api. |
string | $access_token | Access token. |
array|string | $profile_ids | An array of Buffer profile id’s of an individual id that the status update should be sent to. |
string | $text | The status update text. |
array | $media | An associative array of media to be attached to the update containing some of the following parameters: link, description, title, picture, photo, thumbnail. |
boolean | $attachment | Whether a link in the text should automatically populate the media parameter if media is empty. |
boolean | $shorten | If shorten is false links within the text will not be automatically shortened, otherwise they will. |
boolean | $now | If now is set, this update will be sent immediately to all profiles instead of being added to the buffer. |
boolean | $top | If top is set, this update will be added to the top of the buffer and will become the next update sent. |
integer | $timeout | Maximum number of seconds to wait for a response (default 15 seconds). |
Returns
boolean|\WP_Error —Returns true on success or a WP_Error in case an error occurred.