プラットフォームメタデータ
curl --request GET \
--url https://api.example.com/v1/metaimport requests
url = "https://api.example.com/v1/meta"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/meta', 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.example.com/v1/meta",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.example.com/v1/meta"
req, _ := http.NewRequest("GET", url, nil)
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.example.com/v1/meta")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/meta")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"currency": "<string>"
}Discovery
プラットフォームメタデータ
デプロイ定数。現時点は請求通貨のみ。
GET
/
v1
/
meta
プラットフォームメタデータ
curl --request GET \
--url https://api.example.com/v1/metaimport requests
url = "https://api.example.com/v1/meta"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/meta', 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.example.com/v1/meta",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.example.com/v1/meta"
req, _ := http.NewRequest("GET", url, nil)
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.example.com/v1/meta")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/meta")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"currency": "<string>"
}GET https://api-datahub.octoparse.com/v1/meta
認証:不要。匿名で呼び出し可能。
デプロイ単位の定数。現時点は請求通貨(ISO 4217)のみ。金額フィールド(unit_price、amount、total_spent)自体に単位はなく、単位はここから取る。国際デプロイは USD。
匿名読み取りがあるのは、未ログインでも市場カードの開始価格に通貨を出せるようにするため。
リクエスト
リクエスト例
curl "https://api-datahub.octoparse.com/v1/meta"
レスポンス
200 成功
{
"data": {
"currency": "USD"
}
}
data に包まれます。フィールド:
string
請求通貨(ISO 4217)。
クライアントライブラリ
meta = client.meta()
print(meta["currency"])
const meta = await client.meta();
console.log(meta.currency);