Find similar mentions
curl --request GET \
--url https://api.nephia.cc/v1/mentions/{id}/similar \
--header 'x-api-key: <api-key>'import requests
url = "https://api.nephia.cc/v1/mentions/{id}/similar"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.nephia.cc/v1/mentions/{id}/similar', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.nephia.cc/v1/mentions/{id}/similar",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.nephia.cc/v1/mentions/{id}/similar"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.nephia.cc/v1/mentions/{id}/similar")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nephia.cc/v1/mentions/{id}/similar")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"mentions": [
{
"id": "<string>",
"source": "x",
"type": "listing.created",
"occurredAt": "<string>",
"publishedAt": "<string>",
"query": {
"id": "<string>",
"name": "<string>"
},
"run": {
"id": "<string>",
"name": "<string>"
},
"title": "<string>",
"body": "<string>",
"url": "<string>",
"metaLabel": "<string>",
"sentiment": "positive",
"intent": "purchase_intent",
"matchedTerms": [
"<string>"
],
"authorHandle": "<string>",
"marks": [
"to_reply"
],
"agent": {},
"media": {
"thumbnailUrl": "<string>",
"imageUrls": [
"<string>"
],
"avatarUrl": "<string>",
"durationLabel": "<string>"
},
"fields": [
{
"label": "<string>",
"value": "<string>"
}
],
"duplicateOf": "<string>",
"duplicateCount": 123,
"seeded": true
}
],
"meta": {
"credits_used": 123
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "Rate limit exceeded",
"code": "TOO_MANY_REQUESTS"
}{
"error": "<string>",
"code": "<string>"
}Mentions
Find similar mentions
Up to ten mentions that say something close to this one, most similar first, across every Query and kept Explore run on the Account. The id is a mention’s id from any mention read, collected in the last 30 days. Copies of the same post are collapsed and the mention you asked about never comes back. Charges 1 credit per mention asked about, then answers the same mention free for 10 minutes; a different mention charges again. meta.credits_used is what this call charged.
GET
/
v1
/
mentions
/
{id}
/
similar
Find similar mentions
curl --request GET \
--url https://api.nephia.cc/v1/mentions/{id}/similar \
--header 'x-api-key: <api-key>'import requests
url = "https://api.nephia.cc/v1/mentions/{id}/similar"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.nephia.cc/v1/mentions/{id}/similar', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.nephia.cc/v1/mentions/{id}/similar",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.nephia.cc/v1/mentions/{id}/similar"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.nephia.cc/v1/mentions/{id}/similar")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nephia.cc/v1/mentions/{id}/similar")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"mentions": [
{
"id": "<string>",
"source": "x",
"type": "listing.created",
"occurredAt": "<string>",
"publishedAt": "<string>",
"query": {
"id": "<string>",
"name": "<string>"
},
"run": {
"id": "<string>",
"name": "<string>"
},
"title": "<string>",
"body": "<string>",
"url": "<string>",
"metaLabel": "<string>",
"sentiment": "positive",
"intent": "purchase_intent",
"matchedTerms": [
"<string>"
],
"authorHandle": "<string>",
"marks": [
"to_reply"
],
"agent": {},
"media": {
"thumbnailUrl": "<string>",
"imageUrls": [
"<string>"
],
"avatarUrl": "<string>",
"durationLabel": "<string>"
},
"fields": [
{
"label": "<string>",
"value": "<string>"
}
],
"duplicateOf": "<string>",
"duplicateCount": 123,
"seeded": true
}
],
"meta": {
"credits_used": 123
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "Rate limit exceeded",
"code": "TOO_MANY_REQUESTS"
}{
"error": "<string>",
"code": "<string>"
}Was this page helpful?