Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const FB = require('fb');
- FB.setAccessToken('my token is actually here, i just replace it with this text lmao');
- let postContents = 'Hello World!';
- FB.api('me/feed', 'post', { message: postContents }, res => {
- if (!res || res.error) {
- return console.error(!res ? 'error occurred' : res.error);
- }
- console.log(`Post ID: ${res.id}`);
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement