Иногда нужно добавить пост кодом и по URL добавить миниатюру (featured thumbnail).
Пример кода:


<?php
set_time_limit(0);
define('WP_USE_THEMES', true);
require('./wp-blog-header.php');
$title = 'Hello World';
$body = 'Content';
$image_url = 'http://pizdo.biz/wp-content/uploads/2013/03/cropped-logo.png';
 
$post = array(
    'post_title' => $title,
    'post_content' => $body;
    'post_author' => 1,
    'comment_status' => 'closed',
    'ping_status' => 'closed',
    'post_type' => 'post'
 
  //'post_date' => [ Y-m-d H:i:s ] //The time post was made.
  //'ID' => [ <post id> ] //Are you updating an existing post?
  //'post_category' => [ array(<category id>, <...>) ] //Add some categories.
  //'post_date_gmt' => [ Y-m-d H:i:s ] //The time post was made, in GMT.
  //'post_excerpt' => [ <an excerpt> ] //For all your post excerpt needs.
  //'post_name' => [ <the name> ] // The name (slug) for your post
  //'post_parent' => [ <post ID> ] //Sets the parent of the new post.
  //'post_password' => [ ? ] //password for post?
  //'tags_input' => [ '<tag>, <tag>, <...>' ] //For tags.
  //'to_ping' => [ ? ] //?
);
$post_id = wp_insert_post( $post, $wp_error );
 
$upload_dir = wp_upload_dir();
$image_data = file_get_contents($image_url);
$filename = basename($image_url);
if(wp_mkdir_p($upload_dir['path']))
    $file = $upload_dir['path'] . '/' . $filename;
else
    $file = $upload_dir['basedir'] . '/' . $filename;
file_put_contents($file, $image_data);
 
$wp_filetype = wp_check_filetype($filename, null );
$attachment = array(
    'post_mime_type' => $wp_filetype['type'],
    'post_title' => sanitize_file_name($filename),
    'post_content' => '',
    'post_status' => 'inherit'
);
$attach_id = wp_insert_attachment( $attachment, $file, $post_id );
require_once(ABSPATH . 'wp-admin/includes/image.php');
$attach_data = wp_generate_attachment_metadata( $attach_id, $file );
wp_update_attachment_metadata( $attach_id, $attach_data );
set_post_thumbnail( $post_id, $attach_id );
}
?>

Взял тут http://pizdo.biz/posting-v-wordpress-s-tumboj-miniatyuroj-cherez-wp_insert_post-122
По ссылке народ говорит вирусы бывают. Потому мб не стоит туда ходить.