Recognizing 50+ Candlestick patterns

symbol_candle_patterns


Results
This API scan 50+ candlestick patterns on a historical data for any global symbol. A candlestick pattern is a movement in prices shown graphically on a candlestick chart that some believe can predict a particular market movement. Candlestick patterns are great candidates to train machine learning models for attempting to predict future prices. The output of the API will display any dates with respective candlestick patterns. Where values refer as 100 = Bullish, -100 = Bearish pattern

Specification
Endpoint
symbol_candle_patterns?symbol={symbol}&start_date={start_date}&end_date={end_date}

Support
Current and Historical values

API Call Counts
50 per API call.

API Plan
gold



Input Parameters
symbol

The common/local symbol/ticker of the symbol

Example : BTCUSD


start_date

Start Date

Example : 2019-01-01


end_date

End Date

Example : 2019-01-01



Output Descriptions
symbol

The common/local symbol/ticker of the symbol

Type: string


symbol_name

The name of the symbol

Type: string


exchange

the exchange code e.g. gemini

Type: string


symbol_pair

the exchange symbol pairs

Type: string



Sample Output
{
  "status": "ok",
  "info": {
    "symbol": {
      "symbol": "BTCUSD",
      "symbol_name": "Bitcoin/US Dollar",
      "exchange": "gemini",
      "symbol_pair": "BTC/USD"
    },
    "results": [
      {
        "date": "2022-03-22",
        "open_price": 41020.89,
        "high_price": 43359.99,
        "low_price": 40897.34,
        "close_price": 43029.81,
        "volume": 504.96807439,
        "CDLENGULFING": 100
      },
      {
        "date": "2022-03-15",
        "open_price": 39662.51,
        "high_price": 39806.3,
        "low_price": 38645,
        "close_price": 38844.33,
        "volume": 186.04780677,
        "CDLENGULFING": -100,
        "CDLLONGLINE": -100
      },
      {
        "date": "2022-03-14",
        "open_price": 37802.55,
        "high_price": 38920.22,
        "low_price": 37578.09,
        "close_price": 38811.06,
        "volume": 259.72496305,
        "CDL3OUTSIDE": -100,
        "CDLCLOSINGMARUBOZU": 100,
        "CDLCOUNTERATTACK": 100,
        "CDLLONGLINE": 100
      },
      {
        "date": "2022-03-13",
        "open_price": 38815.63,
        "high_price": 39309.13,
        "low_price": 37599,
        "close_price": 37791.31,
        "volume": 488.79461612,
        "CDLENGULFING": -100
      },
      {
        "date": "2022-03-12",
        "open_price": 38747.44,
        "high_price": 39300,
        "low_price": 38676,
        "close_price": 39016.97,
        "volume": 138.04343452,
        "CDLSHORTLINE": 100
      },
      {
        "date": "2022-03-11",
        "open_price": 39434.91,
        "high_price": 39441.61,
        "low_price": 38254.5,
        "close_price": 39070.9,
        "volume": 306.49814446,
        "CDLHANGINGMAN": -100
      },
      {
        "date": "2022-03-10",
        "open_price": 41949.98,
        "high_price": 42043.93,
        "low_price": 38875.81,
        "close_price": 38994.66,
        "volume": 636.3846819,
        "CDLBELTHOLD": -100,
        "CDLLONGLINE": -100,
        "CDLMATCHINGLOW": 100
      },
      {
        "date": "2022-03-09",
        "open_price": 38751.44,
        "high_price": 42590.58,
        "low_price": 38675.08,
        "close_price": 41977.35,
        "volume": 1868.16433527,
        "CDLBELTHOLD": 100,
        "CDLENGULFING": 100
      },
      {
        "date": "2022-03-07",
        "open_price": 38419.7,
        "high_price": 39551.51,
        "low_price": 37176.64,
        "close_price": 38000,
        "volume": 1398.24712105,
        "CDLSPINNINGTOP": -100
      },
      {
        "date": "2022-03-06",
        "open_price": 39413.22,
        "high_price": 39695.51,
        "low_price": 38095,
        "close_price": 38428.45,
        "volume": 671.13969812,
        "CDLSHORTLINE": -100
      },
      {
        "date": "2022-03-04",
        "open_price": 42463.75,
        "high_price": 42513.96,
        "low_price": 38588.89,
        "close_price": 39168,
        "volume": 2507.51995526,
        "CDLBELTHOLD": -100
      },
      {
        "date": "2022-03-03",
        "open_price": 43927.2,
        "high_price": 44136.36,
        "low_price": 41822.75,
        "close_price": 42461.16,
        "volume": 1326.10524172,
        "CDLBELTHOLD": -100
      },
      {
        "date": "2022-03-02",
        "open_price": 44447.85,
        "high_price": 45303,
        "low_price": 43359.61,
        "close_price": 43936.11,
        "volume": 1383.35162013,
        "CDLSPINNINGTOP": -100
      }
    ]
  },
  "total_records": 13,
  "page_size": 13,
  "current_page": 1,
  "total_pages": 1,
  "results": null
}

REST
GET https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key
Python
import requests 
r = requests.get("https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key")
data = r.json()
print(data)
Node.js
var http = require('http');
var buffer = '';
var options = {
	host: 'https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key',
	port: 80,
	path: 'https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key',
	headers: headers
};
callback = function(response) {
	response.on('data', function (chunk) {
	buffer += chunk;
});
response.on('end', function () {
	// your code here if you want to use the results !
});
}

var req = http.get(options, callback).end();
C#
using (var client = new HttpClient())
{
	client.BaseAddress = new Uri("{$api_host}");
	client.DefaultRequestHeaders.Clear();
	//ADD Acept Header to tell the server what data type you want
	client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
	//SET Parameters
	HttpResponseMessage response = await client.GetAsync("https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key");
	if (response.IsSuccessStatusCode)
	{
		//Your custom response parser code
	}
}
Java
String uri = "https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key";
URL url = new URL(uri);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
	connection.setRequestMethod("GET");
	connection.setRequestProperty("Accept", "application/json");
InputStream xml = connection.getInputStream();
R
1 - Install package
install.packages("RCurl")
install.packages("jsonlite")
2 - Request the data:
library('RCurl')
require('jsonlite')
json <- getURL(URLencode('https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key'))
obj <- fromJSON(json)
PHP
$url = 'https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key';
$handle = curl_init(); 
	curl_setopt($handle, CURLOPT_URL, $url);
	curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);

	$data = curl_exec($handle);
curl_close($handle);
//parse your data as per your needs....
Javascript
var url = 'https://www.cryptoquote.io/analytics/v1/?api=symbol_candle_patterns&symbol=BTCUSD.gdax&start_date=2022-03-01&end_date=2022-03-27&price_field=close_price&period=14&key=your_api_key';
$.ajax({
		url: url,
		type: "GET",
		dataType: 'json'
}).done(function (data) {
	console.log(data);
});