SDK
import { createVoyantDataClient } from "@voyant-travel/data-sdk";
const data = createVoyantDataClient({ apiKey: process.env.VOYANT_API_KEY });
const result = await data.reviews.google.extendedReviews.create({});curl --request POST \
--url https://api.voyant.travel/data/reviews/v1/google/extended-reviews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'const response = await fetch("https://api.voyant.travel/data/reviews/v1/google/extended-reviews", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <token>"
},
body: JSON.stringify({}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.voyant.travel/data/reviews/v1/google/extended-reviews",
headers={
"Authorization": "Bearer <token>"
},
json={}
)
data = response.json()<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.voyant.travel/data/reviews/v1/google/extended-reviews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.voyant.travel/data/reviews/v1/google/extended-reviews"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.voyant.travel/data/reviews/v1/google/extended-reviews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.voyant.travel/data/reviews/v1/google/extended-reviews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"status": "queued",
"createdAt": "2023-11-07T05:31:56Z",
"request": {},
"completedAt": "2023-11-07T05:31:56Z",
"result": {},
"cost": {
"credits": 123
},
"error": {
"code": "<string>",
"message": "<string>"
},
"webhook": {
"url": "<string>",
"deliveredAt": "2023-11-07T05:31:56Z",
"attempts": 123,
"lastError": "<string>"
}
}
}{
"code": "NOT_FOUND",
"message": "<string>"
}{
"code": "NOT_FOUND",
"message": "<string>"
}Reviews
Submit a Google Extended Reviews job
Submit an async Google Extended Reviews job (same request envelope as Google Reviews). Requires scope data:reviews:read.
POST
/
data
/
reviews
/
v1
/
google
/
extended-reviews
SDK
import { createVoyantDataClient } from "@voyant-travel/data-sdk";
const data = createVoyantDataClient({ apiKey: process.env.VOYANT_API_KEY });
const result = await data.reviews.google.extendedReviews.create({});curl --request POST \
--url https://api.voyant.travel/data/reviews/v1/google/extended-reviews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'const response = await fetch("https://api.voyant.travel/data/reviews/v1/google/extended-reviews", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <token>"
},
body: JSON.stringify({}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.voyant.travel/data/reviews/v1/google/extended-reviews",
headers={
"Authorization": "Bearer <token>"
},
json={}
)
data = response.json()<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.voyant.travel/data/reviews/v1/google/extended-reviews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.voyant.travel/data/reviews/v1/google/extended-reviews"
payload := strings.NewReader("{}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.voyant.travel/data/reviews/v1/google/extended-reviews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.voyant.travel/data/reviews/v1/google/extended-reviews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"status": "queued",
"createdAt": "2023-11-07T05:31:56Z",
"request": {},
"completedAt": "2023-11-07T05:31:56Z",
"result": {},
"cost": {
"credits": 123
},
"error": {
"code": "<string>",
"message": "<string>"
},
"webhook": {
"url": "<string>",
"deliveredAt": "2023-11-07T05:31:56Z",
"attempts": 123,
"lastError": "<string>"
}
}
}{
"code": "NOT_FOUND",
"message": "<string>"
}{
"code": "NOT_FOUND",
"message": "<string>"
}Authorizations
Voyant Data API token, scoped per sub-product (data:{product}:read). Sent as Authorization: Bearer <token>.
Body
application/json
Provider passthrough record (camelCased on the wire). Kept open so provider-side field additions do not break clients.
Response
Created resource
Show child attributes
Show child attributes
⌘I