client-cli icon indicating copy to clipboard operation
client-cli copied to clipboard

Sorry, you are not allowed to create new posts

Open robtown opened this issue 9 years ago • 0 comments

Has anybody successfully created posts from an Ionic app? I have an ionic app successfully negotiating the first leg of the oauth 1.0a process, but when I try to actually create a post I get an rest_cannot_create error.

Response from service:

Error creating post! {"data":{"code":"rest_cannot_create","message":"Sorry, you are not allowed to create new posts.","data":{"status":401}},"status":401,"config":{"method":"POST","transformRequest":[null],"transformResponse":[null],"url":"http://service.com/wp-json/wp/v2/posts","data":{"title":"Foo title","content":"Foo content","status":"publish"},"headers":{"Accept":"application/json, text/plain, /","Authorization":"OAuth oauth_consumer_key="1fuYx4bx8EOM", oauth_nonce="rGAQfWZwq4cecXlzMdQBiG7cR673I0Lx", oauth_timestamp="1459875496", oauth_signature_method="HMAC-SHA1", oauth_token="bIDQOcdep8jf0jLg6cF1wpHX", oauth_version="1.0", oauth_signature="EPj%2FRCgf%2BlKXnFB9F5q0Vn7Njg8%3D"","Content-Type":"application/json;charset=utf-8"}},"statusText":"Unauthorized"}

robtown avatar Apr 05 '16 16:04 robtown