Skip to content

Instantly share code, notes, and snippets.

View Anderson-Juhasc's full-sized avatar
:octocat:
Looking for work

Anderson Juhasc Anderson-Juhasc

:octocat:
Looking for work
View GitHub Profile
// constructor
function Bot(api_key, secret) {
var self = this;
self.ticker = null;
if (channels) {
self.subscribe(channels);
}
<!DOCTYPE HTML>
<html lang="en" ng-app="app">
<head>
<meta charset="UTF-8">
<title></title>
</head>
<body>
<div ng-controller="ctrl"></div>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.5/angular.min.js"></script>
$.ajax({
type: "GET",
url: "http://query.yahooapis.com/v1/public/yql",
jsonp: "callback",
dataType: "jsonp",
data: {
q: 'select * from html where url = "http://api.bitvalor.com/v1/ticker.json"',
format: 'json'
},
success: function(response) {
<?php
use Blocktrail\SDK\BlocktrailSDK;
$value = BlocktrailSDK::toSatoshi(1.1);
$wallet->pay(array('1NcXPMRaanz43b1kokpPuYDdk6GGDvxT2T' => $value));
var symbol = "R$"
, timer = 10000;
getTicker();
setInterval(function(){
getTicker();
}, timer);
<?php
$pagCoinUrl = "https://pagcoin.com/api/v1/CriarInvoice/?modo=json";
$request = array(
"apiKey" => "dummy",
"valorEmMoedaOriginal" => 123.45,
"nomeProduto" => "Nome do produto ou serviço vendido",
"idInterna" => "109856482",
"email" => "[email protected]",
"redirectURL" => "http://www.sitedesualoja.com/URL/Para/Redirecionar/?usuario=aposACompra"
function BTCFoxBitCompra(currency){
if (currency == null) {
currency = "brl";
}
var url = "https://api.blinktrade.com/api/v1/BRL/orderbook...";
setInterval(function(){
var response = UrlFetchApp.fetch(url).getResponseCode();
if (response = 200) {
var btcbasedata = UrlFetchApp.fetch(url).getContentText();
var object = JSON.parse(btcbasedata);
Bitex.prototype.requestOrderList = function(opt_requestId, opt_page, opt_limit, opt_filter){
var self = this
, reqId = opt_requestId || parseInt( 1e7 * Math.random() , 10 )
, page = opt_page || 0
, limit = opt_limit || 10
, msg = {
'MsgType': 'U4',
'OrdersReqID': reqId,
'Page': page,
'PageSize': limit,
var Bitcore = require('bitcore');
var Insight = require('bitcore-explorers').Insight;
var insight = new Insight();
insight.getUnspentUtxos('12S3tMNDJAnwPCcKwwQRgtPuiUs5sSkgHg', function(err, utxos) {
if (err) {
// Handle errors...
} else {
// Maybe use the UTXOs to create a transaction
console.log(utxos);