Can’t believe it? Launch Rebol’s Console, and copy and paste this:
do http://reboltutorial.com/source/rebol-twitter.r
You can now tweet in one line by typing:
tweet "Hello World!"
Nevertheless do not forget the quote (you can also write a multiple-lines message using braces {}).
The first time it will ask your login and password:

The second and next time, you don’t need to re-enter your login and password:

You can switch to another account with the tweetaccount command like this:
tweetaccount "reboltutorial" "thisisnotmytruepassword!" "So you cannot try this for real !"
This is the code behind the tweet and tweetaccount functions:
Rebol [
Title: "Rebol Twitter"
Author-Url: http://reboltutorial.com/blog/rebol-twitter-update/
Script-Url: http://reboltutorial.com/source/rebol-twitter.r
Date: 23-Aug-2009
Purpose: {
Tweet from Rebol - Multiple Accounts support
}
]
;it uses this library to do http post with basic authentication as requested by the tweeter API
do http://reboltutorial.com/source/http-tools.r
tweetaccount: func[user password message][
tweetuser: user
tweetpassword: password
http-tools-data/username: user
http-tools-data/password: password
message-block: copy []
append message-block "status"
append message-block message
http-tools/post http://twitter.com/statuses/update.json message-block
]
tweet: func [message][
if not (value? 'tweetuser) [
tweetuser: ask "user: "
tweetpassword: ask "password: "
]
tweetaccount tweetuser tweetpassword message
]
![]()















Your subtitle: Learn Rebol Day by Day with Real-Word Examples, I believe you meant World?
Oops you’re right !!! Have corrected thanks
Cool. I’ve been looking for something like this.
BTW, nice website.
Also to note: the /install link was 404 when I tried it.
No kidding, are you really Carl ? If yes hope you learned something
Thanks /install is a redirection, it works for me but it seems it doesn’t work for everybody so I changed all links to direct link to /rebol-download/
First: great website and great topics!
Next: can you tell if the user/password is sent to twitter with or without encryption? I could check myself but if you know the answer right away then you save me some time
Thanks!
It uses twitter API which doesn’t use encryption. It’s no less safer than when you connect to twitter with your browser: it uses http protocol like itself.
Or if encryption is possible can you point me to the twitter API page which says so ?
Just use https instead of http in the API request URLs, then you’ve got SSL encryption. I don’t think this is mentioned in the API docs explicitly, haven’t seen it.
You can do the same when visiting Twitter on the web. Just use https://www.twitter.com instead of http://www.twitter.com
Hi thanks. For people who needs encryption see Professional version of Rebol named Rebol Command
REBOL/Command
Version 2.5.6
# Oracle and MySQL direct interfaces
# ODBC (SQLServer, Access, Excel) database interface
# Access to external libraries (DLLs)
# SSL secure sockets (HTTPS client)
# Built-in RSA, AES, Blowfish, DSA, DH encryption
# Shell commands, launch external apps
# Windows Registry access functions
# Fast CGI server interface
http://www.rebol.com/download.html
Those features are now available in the free versions of REBOL VIEW 2.76 and Beta
Woowwwwww Great News will test them !!!!!!!!!!!!!!!!!!!!
i see it doesnt have IPv6 capabilitys, thats a shame, is that coming soon or not ?
As far as I can read “Upcoming releases of REBOL hopefully (and likely) will.” http://www.rebol.org/documentation.r?script=oneliner-tcp-port-scanner.r