I hereby claim:
- I am charleyhine on github.
- I am charley (https://keybase.io/charley) on keybase.
- I have a public key whose fingerprint is CB9F EC53 0F65 E580 BFE1 A27E F929 A025 4978 14B8
To claim this, I am signing this object:
{ | |
"address": { | |
"address": "1kf93kf...", | |
"transaction": { | |
"hash": "48d4425e68...", | |
"address_sent": 0, | |
"address_received": 4000, | |
"confirmations": 5 | |
} | |
} |
def result | |
tx = JSON.parse(request.raw_post) | |
type = tx['payload']['type'] | |
confs = tx['payload']['confirmations'] | |
amount_s = tx['payload']['received'] | |
tx_id = tx['payload']['transaction_hash'] | |
addr = tx['payload']['address'] | |
render nothing: true, status: 200 | |
end |
btc_key = Bitcoin::Key.from_base58(get_path_pk(sig)) | |
hash = @btc_r_tx.signature_hash_for_input(input['input_index'], input['redeem_script']) | |
signat = btc_key.sign(hash) |
btc_r_tx = Bitcoin::P::Tx.new(tx_data) | |
btc_r_key = Bitcoin::Key.from_base58(private_key) | |
hash = btc_r_tx.signature_hash_for_input(input_index, redeem_script) | |
btc_r_key.sign(hash) |
I hereby claim:
To claim this, I am signing this object:
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
import java.net.URL; | |
import java.net.HttpURLConnection; | |
import java.nio.charset.Charset; | |
private String getResponse(URL url){ | |
try { | |
HttpURLConnection c = url.openConnection(); | |
c.setReadTimeout(1000); // 1 second |
status code 401
{
"error": {
"type": "invalid_request_error",
"message": "Authentication to the API occurs via HTTP Basic Auth"
}
}
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
Custodians (companies and developers) integrate with the Shift API to create and manage branded debit cards and cardholder data. We've tried to make this documentation user-friendly and example-filled, but please drop us a line with any questions. If you're planning to use our API in production, you should take a look at Metropolitan Commercial Bank's privacy policy.
require 'httparty' | |
require 'pp' | |
class Tesla | |
TESLA_CLIENT_ID = '81527cff06843c8634fdc09e8ac0abefb46ac849f38fe1e431c2ef2106796384' | |
TESLA_CLIENT_SECRET = 'c7257eb71a564034f9419ee651c7d0e5f7aa6bfbd18bafb5c5c033b093bb2fa3' | |
include HTTParty | |
base_uri 'https://owner-api.teslamotors.com' |