curl --location --request GET 'https://api.ayrshare.com/ayrshare/api/hashtags/banned?hashtag=%23bikinibody' \
--header 'Authorization: Bearer API_KEY'
const myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer API_KEY");
const urlencoded = new URLSearchParams();
const requestOptions = {
method: 'GET',
headers: myHeaders,
};
fetch("https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody", requestOptions)
.then(response => response.json())
.then(result => console.log(result))
.catch(error => console.log('error', error));
import requests
# Your API key
API_KEY = "Bearer API_KEY"
# Headers
headers = {
"Authorization": API_KEY
}
# URL
url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody"
# Making the GET request
response = requests.get(url, headers=headers)
# Checking if the request was successful
if response.status_code == 200:
# Parse JSON response
result = response.json()
print(result)
else:
print("Error:", response.status_code)
<?php
// Your API key
$apiKey = "Bearer API_KEY";
// URL
$url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
// Initialize cURL session
$ch = curl_init($url);
// Set cURL options
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: $apiKey"
]);
// Execute cURL session
$response = curl_exec($ch);
// Check if any error occurred
if(curl_errno($ch)) {
echo 'Curl error: ' . curl_error($ch);
} else {
// Decode JSON response
$result = json_decode($response, true);
echo print_r($result, true);
}
// Close cURL session
curl_close($ch);
?>
using System;
using System.Net.Http;
using System.Threading.Tasks;
namespace ConsoleApp
{
class Program
{
static async Task Main(string[] args)
{
// Your API key
string apiKey = "Bearer API_KEY";
// URL
string url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
using (var httpClient = new HttpClient())
{
// Set the Authorization header with your API key
httpClient.DefaultRequestHeaders.Add("Authorization", apiKey);
try
{
// Make the GET request
HttpResponseMessage response = await httpClient.GetAsync(url);
if (response.IsSuccessStatusCode)
{
// Read the response content as a string
string result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
}
else
{
Console.WriteLine($"Error: {response.StatusCode}");
}
}
catch (HttpRequestException e)
{
Console.WriteLine($"Request exception: {e.Message}");
}
}
}
}
}
{
"hashtag": "#bikinibody",
"banned": true
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. .../ayrshare.com/rest-api/endpoints"
}
Hashtags
Check Banned Hashtags
A banned hashtag checker
GET
/
hashtags
/
banned
curl --location --request GET 'https://api.ayrshare.com/ayrshare/api/hashtags/banned?hashtag=%23bikinibody' \
--header 'Authorization: Bearer API_KEY'
const myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer API_KEY");
const urlencoded = new URLSearchParams();
const requestOptions = {
method: 'GET',
headers: myHeaders,
};
fetch("https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody", requestOptions)
.then(response => response.json())
.then(result => console.log(result))
.catch(error => console.log('error', error));
import requests
# Your API key
API_KEY = "Bearer API_KEY"
# Headers
headers = {
"Authorization": API_KEY
}
# URL
url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody"
# Making the GET request
response = requests.get(url, headers=headers)
# Checking if the request was successful
if response.status_code == 200:
# Parse JSON response
result = response.json()
print(result)
else:
print("Error:", response.status_code)
<?php
// Your API key
$apiKey = "Bearer API_KEY";
// URL
$url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
// Initialize cURL session
$ch = curl_init($url);
// Set cURL options
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: $apiKey"
]);
// Execute cURL session
$response = curl_exec($ch);
// Check if any error occurred
if(curl_errno($ch)) {
echo 'Curl error: ' . curl_error($ch);
} else {
// Decode JSON response
$result = json_decode($response, true);
echo print_r($result, true);
}
// Close cURL session
curl_close($ch);
?>
using System;
using System.Net.Http;
using System.Threading.Tasks;
namespace ConsoleApp
{
class Program
{
static async Task Main(string[] args)
{
// Your API key
string apiKey = "Bearer API_KEY";
// URL
string url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
using (var httpClient = new HttpClient())
{
// Set the Authorization header with your API key
httpClient.DefaultRequestHeaders.Add("Authorization", apiKey);
try
{
// Make the GET request
HttpResponseMessage response = await httpClient.GetAsync(url);
if (response.IsSuccessStatusCode)
{
// Read the response content as a string
string result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
}
else
{
Console.WriteLine($"Error: {response.StatusCode}");
}
}
catch (HttpRequestException e)
{
Console.WriteLine($"Request exception: {e.Message}");
}
}
}
}
}
{
"hashtag": "#bikinibody",
"banned": true
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. .../ayrshare.com/rest-api/endpoints"
}
A banned hashtag checker to validate if the given hashtag has been banned by Instagram or other social networks.
Header Parameters
Query Parameters
The hashtag to validate. Format: “hashtag” or “#hashtag”
curl --location --request GET 'https://api.ayrshare.com/ayrshare/api/hashtags/banned?hashtag=%23bikinibody' \
--header 'Authorization: Bearer API_KEY'
const myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer API_KEY");
const urlencoded = new URLSearchParams();
const requestOptions = {
method: 'GET',
headers: myHeaders,
};
fetch("https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody", requestOptions)
.then(response => response.json())
.then(result => console.log(result))
.catch(error => console.log('error', error));
import requests
# Your API key
API_KEY = "Bearer API_KEY"
# Headers
headers = {
"Authorization": API_KEY
}
# URL
url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody"
# Making the GET request
response = requests.get(url, headers=headers)
# Checking if the request was successful
if response.status_code == 200:
# Parse JSON response
result = response.json()
print(result)
else:
print("Error:", response.status_code)
<?php
// Your API key
$apiKey = "Bearer API_KEY";
// URL
$url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
// Initialize cURL session
$ch = curl_init($url);
// Set cURL options
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: $apiKey"
]);
// Execute cURL session
$response = curl_exec($ch);
// Check if any error occurred
if(curl_errno($ch)) {
echo 'Curl error: ' . curl_error($ch);
} else {
// Decode JSON response
$result = json_decode($response, true);
echo print_r($result, true);
}
// Close cURL session
curl_close($ch);
?>
using System;
using System.Net.Http;
using System.Threading.Tasks;
namespace ConsoleApp
{
class Program
{
static async Task Main(string[] args)
{
// Your API key
string apiKey = "Bearer API_KEY";
// URL
string url = "https://api.ayrshare.com/api/hashtags/banned?hashtag=%23bikinibody";
using (var httpClient = new HttpClient())
{
// Set the Authorization header with your API key
httpClient.DefaultRequestHeaders.Add("Authorization", apiKey);
try
{
// Make the GET request
HttpResponseMessage response = await httpClient.GetAsync(url);
if (response.IsSuccessStatusCode)
{
// Read the response content as a string
string result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
}
else
{
Console.WriteLine($"Error: {response.StatusCode}");
}
}
catch (HttpRequestException e)
{
Console.WriteLine($"Request exception: {e.Message}");
}
}
}
}
}
{
"hashtag": "#bikinibody",
"banned": true
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. .../ayrshare.com/rest-api/endpoints"
}
⌘I
