Introduction

Welcome to the Kushy API! You can use our API to access Kushy API endpoints, which can get information on various cannabis strains, products, shops, and brands in our database.

We have language bindings in Javascript and PHP! You can view code examples in the dark area to the right, and you can switch the programming language of the examples with the tabs in the top right. Find example apps and more on our Github.

Authentication

import axios from axios;
axios.get('http://api.kushy.net/api/1.1/tables/rows')
.then() {

Kushy allows for GET requests from any public request, just request your data and go!

As a verified developer you'll gain access to API keys to allow POST, PUT, and DELETE requests. You can register a new Kushy API key at our developer portal.

Strains

Get All Strains

var api = 'http://api.kushy.net/api/1.1/tables/strains/rows'; 
var xmlhttp;
xmlhttp = new XMLHttpRequest();
xmlhttp.onreadystatechange = function(){
if (xmlhttp.readyState == 4 && xmlhttp.status == 200){
strains = JSON.parse(this.responseText);
console.log(strains);
}
}
xmlhttp.open("GET", api, true);
xmlhttp.send();
// The above command returns JSON structured like this:
[ 
meta: {
table: "strains",
type: "collection",
total: 20,
total_entries: 0
},
data: [
{
id: 1,
status: 1,
sort: 0,
name: "100 OG",
slug: null,
image: "http://fadedfools.com/medical_marijuana/100dollar_og_kush.jpg",
description: "This strain is named after it's high price in it's Hollywood home. As a 50/50 hybrid of indica and sativa, $100 OG does a great job offering pain relief with an alert, cerebral high.",
type: "Hybrid",
crosses: "",
breeder: "Old School Breeder's Association",
effects: "Focused",
ailment: "Depression",
flavor: "Citrus",
location: null,
terpenes: "Limonene",
thc: 127,
thca: 0,
thcv: 0,
cbd: 16,
cbda: 0,
cbdv: 0,
cbn: 10,
cbg: 0,
cbgm: 0,
cbgv: 0,
cbc: 0,
cbcv: 0,
cbv: 0,
cbe: 0,
cbt: 0,
cbl: 0
}]
}
}

Kushy allows for GET requests from any public request, just request your data and go!

As a verified developer you'll gain access to API keys to allow POST, PUT, and DELETE requests. You can register a new Kushy API key at our developer portal.

Get Single Strain

<?php 
$api = 'http://api.kushy.net/api/1.1/tables/strains/rows';
$curl = curl_init();

curl_setopt_array($curl, array(
CURLOPT_URL => $api,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"cache-control: no-cache"
),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);
$response = json_decode($response, true);
echo 'Strain Name'. $response['data'][0]['name'];
?>

Kushy allows for GET requests from any public request, just request your data and go!

As a verified developer you'll gain access to API keys to allow POST, PUT, and DELETE requests. You can register a new Kushy API key at our developer portal.