Who wants to make $50 in Bitcoin real quick ?

[b]You need to have a working knowledge of the MBSCURLS xojo plugin. Some experience working with signed API requests is a plus. You also need at least passing knowledge of VB.net.

The task: Simply translate this VB.net code into XOJO using MBSCURLS and you get [h]$50 in shiny bitcoins.[/h][/b]

[code]Imports System.IO
Imports System.Net
Imports System.Text
Imports System.Security.Cryptography

Dim pKey As String = “Public Key Here”
Dim sKey As String = “Private Key Here”

Private Sub CancelAll()

Dim postReq As HttpWebRequest = DirectCast(WebRequest.Create(“https://www.Cryptsy.com/api”), HttpWebRequest)
Dim randomn As String = CLng(DateTime.UtcNow.Subtract(New DateTime(1970, 1, 1)).TotalSeconds)

'//Dependant upon Method
Dim postData As String = “method=cancelallorders&nonce=” & randomn

'//Start Encryption
Dim KeyByte() As Byte = Encoding.ASCII.GetBytes(sKey)
Dim HMAcSha As New HMACSHA512(Encoding.ASCII.GetBytes(sKey))

Dim messagebyte() As Byte = Encoding.ASCII.GetBytes(postData)
Dim hashmessage() As Byte = HMAcSha.ComputeHash(messagebyte)
Dim Sign As String = BitConverter.ToString(hashmessage)

Sign = Sign.Replace("-", “”)

'//Generate Post Information
postReq.Method = “POST”
postReq.KeepAlive = False
postReq.Headers.Add(“Key”, pKey)
postReq.Headers.Add(“Sign”, LCase(Sign))

postReq.ContentType = “application/x-www-form-urlencoded”
postReq.UserAgent = “Mozilla/5.0 (Windows; U; Windows NT 6.1; ru; rv:1.9.2.3) Gecko/20100401 Firefox/4.0 (.NET CLR 3.5.30729)”
postReq.ContentLength = messagebyte.Length

Try
'//Send Request
Dim postreqstream As Stream = postReq.GetRequestStream()
postreqstream.Write(messagebyte, 0, messagebyte.Length)
postreqstream.Close()
Dim postresponse As HttpWebResponse

postresponse = DirectCast(postReq.GetResponse(), HttpWebResponse)

Dim postreqreader As New StreamReader(postresponse.GetResponseStream())

'The Response Text
Dim thepage As String = postreqreader.ReadToEnd
thepage = thepage.Replace(Chr(34), Chr(39))

Scratchpad.Text = Scratchpad.Text & vbNewLine & thepage

Catch ex As Exception
Scratchpad.Text = Scratchpad.Text & vbNewLine & "Cancel All Orders: " & ex.Message
End Try

End Sub
[/code]

[quote=120758:@chris ridgeway][b]You need to have a working knowledge of the MBSCURLS xojo plugin. Some experience working with signed API requests is a plus. You also need at least passing knowledge of VB.net.

The task: Simply translate this VB.net code into XOJO using MBSCURLS and you get [h]$50 in shiny bitcoins.[/h][/b][/quote]

Why not come back to the first post you made https://forum.xojo.com/14365-need-php-expert-for-small-gig-50-up-for-grabs

Or read the one you abandoned ? https://forum.xojo.com/14812-mbscurl-converting-php-to-xojo-halp/0#p120622

[quote]MBScurl - converting PHP to XOJO #halp! Add-Ons
Controls
Follow
Post a Reply
40 views
Original Post
August
Now
6 HOURS AGO
chris ridgeway is not verified 6 hours ago Deleted 4 hours ago by chris ridgeway
4 HOURS AGO

Christian Schmitz 4 hours ago Alpha Testers, Beta Testers, Xojo Pro Europe (Germany)
yes?

Like
Christian Schmitz 4 hours ago Alpha Testers, Beta Testers, Xojo Pro Europe (Germany)
I once had a blog article on how to convert PHP calls to plugin calls for FileMaker
http://www.mbsplugins.de/archive/2014-07-24/Translate_PHP_script_with_CURL/monkeybreadsoftware_blog_archive

it’s similar for Xojo[/quote]

If you really want to find a solution, the best way is to try converting yourself in the first place to show you made the effort, and post what you have, then be consistent enough to work in the same thread so others can participate without seing you fee to new thread time and time again…

In this forum, most people will help you for free if you show you genuinely try to work on a project. Professionals will certainly feel insulted to be offered only 50$ to carry out all the work for you.

Just 2cents …

well the first post… was a different question and the second post I tried to delete, so no substance there. $50 for about 30 min worth of work is definitely fair… looks like your response is mostly trollish, and go figure unhelpful from the purple alien.

But here’s my attempt to get it to work: (The error i get is “authorization not possible, please check your post data”

http://pastebin.com/ZQkT54LL

And here’s the PHP example provided by the API documentation:

http://pastebin.com/4PPsarFi

Cheers.

Could you show what you coded so far?
Maybe I could help?

PS: I don’t accept bit coins.

Calling people who try to help troll is not going to advance much your project. When you need something from others, in general, it is much better to say please. Good luck.

Didn’t see much help sorry. Thanks :slight_smile:

[quote=120852:@Christian Schmitz]Could you show what you coded so far?
Maybe I could help?
PS: I don’t accept bit coins.[/quote]

But here’s my attempt to get it to work: (The error i get is “authorization not possible, please check your post data”

http://pastebin.com/ZQkT54LL

And here’s the PHP example provided by the API documentation:

http://pastebin.com/4PPsarFi

Cheers.

I have paypal.

Perhaps the topic “How to be polite” might apply here.
I agree with Michel (who by the way is one of the more helpful members of this forum)…
And to most people $50 in bitcoins is $0 in electronic gibberish… If Christian continues to help, more power to him, but I for one would not fault him if he didn’t.

PS. this is NOT Stackoverflow (and I know most of you will get the reason for the reference)

I’m glad he’s helpful in most cases.

If this is actually half an hour’s worth of work, 50 dollar bitcoins is actually worth 50 dollars and Chris pays more if takes longer than expected then I really don’t think he giving a bad deal away. I am not offended by the price. I think it sounds good.

It could use the HTTPSocket with no CURL plugin natively. $50 for 10-15 minutes of code conversion doesn’t sound bad… maybe if I finish what I’m working on before 5 I can help :slight_smile:

It looks a little bit like the oauth authentication.
I think I can help him.

Maybe an additional Folder in this Forum for Xojo Job offers would be a good idea?

I think that’s what the Consulting Leads bonus for being part of Xojo Pro is.

I am anticipating having to subcontract a part of a project I’m working on soon and just wrote Dana Brown this morning to ask what is the best way to go about it … her response was:

I was unaware of that resource myself.

I fully agree, but I would say Dave you are also one of more help here!

As far as I know the native httpsocket class doesnt support http 1.1 which Is why I went with MBSCURLS

I have another project I was able to get working because the API is for a different website API that was easier