メインコンテンツへスキップ
GET
/
endpoint
商品リストのリクエスト
curl --request GET \
  --url https://api.example.com/endpoint
import requests

url = "https://api.example.com/endpoint"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://api.example.com/endpoint', 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/endpoint",
  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/endpoint"

	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/endpoint")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/endpoint")

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
このエンドポイントは商品のリストを取得します。
categories または filters クエリパラメーターを使用しない場合、Kameleoon はレスポンスに filters オブジェクトを含めません。

リクエスト

GET https://api.products.kameleoon.com/products

クエリパラメーター

パラメーター必須説明
didStringTrueデバイス ID。KameleoonProducts_device_id クッキーからこの ID を取得します。このエンドポイントを呼び出す前に、バックエンドから取得してください。“Recently Viewed” や “Recommended for You” など、過去のデバイスデータに依存するフィルターまたはアルゴリズムを使用する場合にのみ did を提供します。
sidStringTrue一時的なユーザーセッション ID。KameleoonProducts_session_code クッキーからこの ID を取得します。このエンドポイントを呼び出す前に、バックエンドから取得してください。“Recently Viewed” や “Recommended for You” など、過去のユーザーデータに依存するフィルターまたはアルゴリズムを使用する場合にのみ sid を提供します。
shop_idStringTrueストアキー。Kameleoon アプリの Recommendations > Settings > Store settings で確認できます。必要に応じてカスタマーサクセスマネージャーにキーをお問い合わせください。
limitIntegerFalseAPI が返す結果の最大数。
pageIntegerFalseAPI が返すページの最大数。
locationsArrayFalse場所 ID のカンマ区切りリスト。
brandsArrayFalseフィルタリング用のブランドのカンマ区切りリスト。
merchantsList of stringsFalseフィルタリング用のマーチャントのカンマ区切りリスト。
categoriesList of stringsFalseフィルタリング用のカテゴリのカンマ区切りリスト。
filtersJSON stringFalseフィルターパラメーターを含むオプションのエスケープされた JSON 文字列。例: {"bluetooth":["yes"],"offers":["15% cashback"],"weight":["1.6"]}
filters_search_byJSON stringFalseフィルター検索オプション: namequantitypopularity

レスポンス

名前説明
brandsArrayブランド情報。各オブジェクトにはこれらのプロパティが含まれます。
categoriesArray of objectsカテゴリ情報。各オブジェクトにはこれらのフィールドが含まれます。
filtersArrayフィルター情報。各オブジェクトにはこれらのプロパティが含まれます。
price_rangeObject商品価格の最小値と最大値。これらのプロパティが含まれます。
productsArray of objects商品情報。各オブジェクトにはこれらのプロパティが含まれます。
products_totalInteger商品の合計数。
price_rangesArray of objects価格帯の上限とその範囲内の商品数を表す to および count フィールドを含むオブジェクト。
price_medianInteger商品価格の中央値。

ブランドプロパティ

名前説明
nameStringブランド名。
pictureStringブランド画像 URL。
countIntegerマッチ数。

カテゴリフィールド

名前説明
idStringカテゴリ ID。
nameStringカテゴリ名。
urlStringカテゴリ URL。
url_handleStringカテゴリへのパス。
countNumberカテゴリ内の商品数。
parentString親カテゴリ ID。
aliasString代替カテゴリ名。

フィルタープロパティ

名前説明
filterObjectこれらのプロパティを含みます。

フィルター値フィールド

名前説明
countInteger選択されたフィルターにマッチする商品の合計数。
priorityIntegerフィルターの優先度。
rangesInteger集計結果範囲。
valuesArray of objectsこれらのプロパティを含む値オブジェクト。

値の詳細

名前説明
valueString値ラベル。
countIntegerこのパラメーターを持つ商品の数。

価格帯フィールド

名前説明
minInteger最低価格。
maxInteger最高価格。

商品フィールド

名前説明
brandString商品のブランド。
currencyString商品の通貨。ショップ設定の通貨と一致します。
idString商品 ID。
is_newBoolean商品プロパティ(デフォルトは NULL)。
nameString商品名。
old_priceString商品の以前の価格(デフォルトは 0)。
priceInteger商品価格。
price_formattedString通貨付きの商品価格。
price_full_formattedStringフォーマットされた商品価格(例: “547.67 $”)。
pictureStringKameleoon ストレージ内の商品画像 URL。
urlString商品 URL。
descriptionString商品の説明。
category_idsArray of strings商品のカテゴリ ID。
fashion_featureStringファッションカテゴリ機能(例: “for kids” または “adult”)。
fashion_genderString商品の性別指定。
sales_rateInteger販売された商品の数。
relative_sales_rateInteger販売シェア(%)。
image_URLString元の商品画像への URL。
image_URL_handleString商品画像へのパス。
image_URL_resizedObject画像サイズと対応するパス。
_idString内部 ID。
group_idStringグループ化された商品の識別子。
barcodeString商品のバーコード。
categoriesArray商品カテゴリ。各オブジェクトにはこれらのプロパティが含まれます。

商品カテゴリのプロパティ

名前説明
idStringカテゴリ ID。
nameStringカテゴリ名。
parentString親カテゴリ ID。
paramsArrayこれらのプロパティを含むパラメーターオブジェクト。

パラメータープロパティ

名前説明
keyStringパラメーター名。
valuesArray値のリスト。