Genel Bilgilendirme
Sopyo API ile birlikte Sopyo üzerinde size ait tüm verileri işleyebilir, kendi uygulamalarınız ile entegre edebilirsiniz.
Sopyo API modülümüzü her geçen gün geliştiriyoruz, görüşlerinizi bize destek@sopyo.com adresinden iletebilirsiniz.
Bu belge, API'mızla çalışmak için ihtiyaç duyduğunuz tüm bilgileri sağlamayı amaçlamaktadır
Base URL
https://api.sopyo.dev
Giriş İşlemleri
Login
Token Al
API Token üretmek için bu endpoint i kullanabilirsiniz
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/auth/login" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"api_token\": [
\"string 1\"
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/auth/login"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"api_token": [
"string 1"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/auth/login',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'api_token' => [
'string 1',
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/auth/login'
payload = {
"api_token": [
"string 1"
]
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, Ok):
{
"status": true,
"message": "",
"user": {
"id": 1,
"name": "Sopyo Yazılım",
"email": "bilgi@sopyo.com"
},
"access_token": {
"token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOi8vbG9jYWxob3N0OjgwMDAvYXBpL3YyL2F1dGgvbG9naW4iLCJpYXQiOjE2NjcyMzA1NDgsImV4cCI6MTY2NzMxNjk0OCwibmJmIjoxNjY3MjMwNTQ4LCJqdGkiOiJ1OXhWSUw3MnlNWHZiRmZCIiwic3ViIjoiMSIsInBydiI6IjEzZThkMDI4YjM5MWYzYjdiNjNmMjE5MzNkYmFkNDU4ZmYyMTA3MmUifQ._ZL7f6irN8HrsKlQDddwBQccjV1nZViympxj3ML3wq8",
"expire_in": 1440,
"type": "bearer"
}
}
Received response:
Request failed with error:
Response
Response Fields
user
object
Kullanıcıya ait bilgileri vermektedir.
access_token
object
API erişimi için kullanacağınız token bilgisini vermektedir.
Katalog Yönetimi
Seçenek Grup Yönetimi
Ürün seçenek grupları ile ilgili tüm işlemleri bu bölümde yapabilirsiniz.
Seçenek Grup Listesi
Kimlik doğrulama gerektirir
Seçenek Grup Listesi
// Örnek filtrelemeler
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/variant-group" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/variant-group',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 1,
"name": "Renk",
"values": [
"Beyaz",
"Kırmızı",
"Lacivert",
"Mavi",
"Pembe",
"Gri",
"Siyah",
"Purple"
]
},
{
"id": 2,
"name": "Beden",
"values": [
"L",
"M",
"S",
"XL",
"36",
"37",
"38",
"39",
"40",
"35",
"41"
]
},
{
"id": 9,
"name": "Hafıza",
"values": [
"128GB",
"256GB"
]
},
{
"id": 10,
"name": "RAM",
"values": [
"8GB",
"4GB",
"16GB"
]
}
],
"links": {
"first": "/api/v2/variant-group?page=1",
"last": "/api/v2/variant-group?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "/api/v2/variant-group?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Sonraki »",
"active": false
}
],
"path": "/api/v2/variant-group",
"per_page": 100,
"to": 5,
"total": 5
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Grup id'si
name
string
Grup adı
values
array
Grup değerleri
Seçenek Grubu Ekle
Kimlik doğrulama gerektirir
Ürün seçenek grubu ekleme işleminizi bu bölümde yapabilirsiniz.
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/variant-group" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Beden\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Beden"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/variant-group',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Beden',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group'
payload = {
"name": "Beden"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Televizyon"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Grup id'si
name
string
Grup adı
values
array
Grup değerleri
Seçenek Grubu Göster
Kimlik doğrulama gerektirir
Seçenek grubu kaydı göster
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/variant-group/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/variant-group/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 1,
"name": "Renk",
"values": [
"Beyaz",
"Kırmızı",
"Lacivert",
"Mavi",
"Pembe",
"Gri",
"Siyah",
"Purple"
]
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Grup id'si
name
string
Grup adı
values
array
Grup değerleri
Seçenek Grubu Güncelle
Kimlik doğrulama gerektirir
Ürün seçenek grubu güncelle
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/variant-group/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Beden\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Beden"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/variant-group/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Beden',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/5'
payload = {
"name": "Beden"
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 1,
"name": "Beden"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Grup id'si
name
string
Grup adı
values
array
Grup değerleri
Seçenek Grubu Sil
Kimlik doğrulama gerektirir
Ürün seçenek grubu kaydı sil
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/variant-group/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/variant-group/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Seçenek Değer Listesi
Kimlik doğrulama gerektirir
Seçenek Değer Listesi
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/variant-group/{id}/values?name%5Beq%5D=L&name%5Blike%5D=L&id%5Beq%5D=1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/{id}/values"
);
const params = {
"name[eq]": "L",
"name[like]": "L",
"id[eq]": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/variant-group/{id}/values',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'query' => [
'name[eq]'=> 'L',
'name[like]'=> 'L',
'id[eq]'=> '1',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/{id}/values'
params = {
'name[eq]': 'L',
'name[like]': 'L',
'id[eq]': '1',
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers, params=params)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 8,
"group_id": 2,
"name": "L"
},
{
"id": 9,
"group_id": 2,
"name": "M"
}
],
"links": {
"first": "api/v2/variant-group/2/values?page=1",
"last": "api/v2/variant-group/2/values?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "api/v2/variant-group/2/values?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Sonraki »",
"active": false
}
],
"path": "api/v2/variant-group/2/values",
"per_page": 100,
"to": 12,
"total": 12
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Değer id'si
group_id
integer
Değer grup Id si
name
string
Değer adı
Seçenek Değeri Ekle
Kimlik doğrulama gerektirir
Ürün seçenek değeri ekleme işleminizi bu bölümde yapabilirsiniz.
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/variant-group/{id}/values" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Beden\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/{id}/values"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Beden"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/variant-group/{id}/values',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Beden',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/{id}/values'
payload = {
"name": "Beden"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 41,
"group_id": 2,
"name": "512GB"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Değer id'si
group_id
string
Grup Id
name
string
Değer adı
Seçenek Değeri Göster
Kimlik doğrulama gerektirir
Ürün seçenek değeri işleminizi bu bölümde yapabilirsiniz.
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/variant-group/2/values/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/2/values/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/variant-group/2/values/1',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/2/values/1'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 41,
"group_id": 2,
"name": "512GB"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Değer id'si
group_id
string
Grup Id
name
string
Değer adı
Seçenek Değeri Güncelle
Kimlik doğrulama gerektirir
Ürün seçenek değeri güncelleme işleminizi bu bölümde yapabilirsiniz.
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/variant-group/2/values/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Beden\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/2/values/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Beden"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/variant-group/2/values/1',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Beden',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/2/values/1'
payload = {
"name": "Beden"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 41,
"group_id": 2,
"name": "512GB"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Değer id'si
group_id
string
Grup Id
name
string
Değer adı
Seçenek Değeri Sil
Kimlik doğrulama gerektirir
Ürün seçenek değeri silme işleminizi bu bölümde yapabilirsiniz.
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/variant-group/2/values/1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/variant-group/2/values/1"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/variant-group/2/values/1',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/variant-group/2/values/1'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Ürün Yönetimi
Ürün ile alakalı tüm işlemleri bu alanda yapabilirsiniz
Ürün Listesi
Kimlik doğrulama gerektirir
Ürün Listesi
// Örnek filtrelemeler
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/products" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/products',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"title": "Varyantsız Ürün Örneği",
"stock_code": "SPYAPITEST005",
"stock": 60,
"category_id": 415750,
"desi": 5,
"tax_rate": 8,
"sub_title": "",
"barcode": "SPYAPITEST005",
"brand": "Bot",
"tag_id": 213,
"description": "Varyantsız Ürün Örneği",
"images": [
"https://app.sopyo.com/public/products/a3150a3c93a90eb882dbecb5e3d7f8f9.jpg",
"https://app.sopyo.com/public/products/9e15adb60acffcd98af06e02c7241a8a.jpg",
"https://app.sopyo.com/public/products/516c4c59ab7a0d900f402c9fb07ef96f.jpg"
],
"price1": [
{
"sale_price": 1500,
"list_price": 2500
}
]
}
],
"links": {
"first": "api/v2/products?page=1",
"last": "api/v2/products?page=2405",
"prev": null,
"next": "api/v2/products?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 2405,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "api/v2/products?page=1",
"label": "1",
"active": true
},
{
"url": "api/v2/products?page=2",
"label": "2",
"active": false
},
{
"url": "api/v2/products?page=3",
"label": "3",
"active": false
},
{
"url": "api/v2/products?page=4",
"label": "4",
"active": false
},
{
"url": "api/v2/products?page=5",
"label": "5",
"active": false
},
{
"url": "api/v2/products?page=6",
"label": "6",
"active": false
},
{
"url": "api/v2/products?page=7",
"label": "7",
"active": false
},
{
"url": "api/v2/products?page=8",
"label": "8",
"active": false
},
{
"url": "api/v2/products?page=9",
"label": "9",
"active": false
},
{
"url": "api/v2/products?page=10",
"label": "10",
"active": false
},
{
"url": null,
"label": "...",
"active": false
},
{
"url": "api/v2/products?page=2404",
"label": "2404",
"active": false
},
{
"url": "api/v2/products?page=2405",
"label": "2405",
"active": false
},
{
"url": "api/v2/products?page=2",
"label": "Sonraki »",
"active": false
}
],
"path": "api/v2/products",
"per_page": 2,
"to": 2,
"total": 4810
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Ürün id'si
title
string
Ürün adı
sub_title
string
Ürün alt başlığı
stock
string
Ürün stok bilgisi
stock_code
string
Ürün stok kodu bilgisi
barcode
string
Ürün barkod bilgisi
barcode_2
string
Ürün ikinci barkod bilgisi
tax_rate
integer
Ürün KDV oranı bilgisi
currency
string
Ürün satış para birimi bilgisi
description
string
Ürün açıklaması
brand
string
Ürün marka bilgisi
desi
string
Ürün desi bilgisi
source
string
Ürünün hangi kaynak üzerinden sisteme eklendiği bilgisini vermektedir
category
object
Ürünün kategori bilgisini vermektedir
images
array
Ürün resimlerinin URL adres bilgilerini vermektedir.
variants
array
Ürün varyantlarını vermektedir.
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Ekle
Kimlik doğrulama gerektirir
Yeni ürün kaydı oluştur
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/products" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Çamaşır Mandalı\",
\"stock_code\": \"87484554\",
\"stock\": 45,
\"category_id\": 25,
\"desi\": 5,
\"tax_rate\": 18,
\"sub_title\": \"Gökkuşağı temalı çamaşır mandalı\",
\"barcode\": \"5EASDF522\",
\"barcode_2\": \"5EAEF525\",
\"brand\": \"YILDIZ\",
\"description\": \"Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.\",
\"price1\": [
{
\"sale_price\": \"7\",
\"list_price\": \"3.31\"
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/products"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Çamaşır Mandalı",
"stock_code": "87484554",
"stock": 45,
"category_id": 25,
"desi": 5,
"tax_rate": 18,
"sub_title": "Gökkuşağı temalı çamaşır mandalı",
"barcode": "5EASDF522",
"barcode_2": "5EAEF525",
"brand": "YILDIZ",
"description": "Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.",
"price1": [
{
"sale_price": "7",
"list_price": "3.31"
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/products',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'title' => 'Çamaşır Mandalı',
'stock_code' => '87484554',
'stock' => 45,
'category_id' => 25,
'desi' => 5.0,
'tax_rate' => 18.0,
'sub_title' => 'Gökkuşağı temalı çamaşır mandalı',
'barcode' => '5EASDF522',
'barcode_2' => '5EAEF525',
'brand' => 'YILDIZ',
'description' => 'Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.',
'price1' => [
[
'sale_price' => '7',
'list_price' => '3.31',
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products'
payload = {
"title": "Çamaşır Mandalı",
"stock_code": "87484554",
"stock": 45,
"category_id": 25,
"desi": 5,
"tax_rate": 18,
"sub_title": "Gökkuşağı temalı çamaşır mandalı",
"barcode": "5EASDF522",
"barcode_2": "5EAEF525",
"brand": "YILDIZ",
"description": "Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.",
"price1": [
{
"sale_price": "7",
"list_price": "3.31"
}
]
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
[
{
"title": "Varyantsız Ürün Örneği",
"stock_code": "SPYAPITEST005",
"stock": 60,
"category_id": 415750,
"desi": 5,
"tax_rate": 8,
"sub_title": "",
"barcode": "SPYAPITEST005",
"brand": "Bot",
"tag_id": 213,
"description": "Varyantsız Ürün Örneği",
"images": [
"https://app.sopyo.com/public/products/a3150a3c93a90eb882dbecb5e3d7f8f9.jpg",
"https://app.sopyo.com/public/products/9e15adb60acffcd98af06e02c7241a8a.jpg",
"https://app.sopyo.com/public/products/516c4c59ab7a0d900f402c9fb07ef96f.jpg"
],
"price_1": [
{
"sale_price": 1500,
"list_price": 2500
}
]
},
{
"id": 18248770,
"title": "Varyantlı Ürün Örneği",
"sub_title": "",
"stock": 0,
"stock_code": "HBCV00002Z3YQM",
"barcode": "8683323005482",
"barcode_2": null,
"tax_rate": 8,
"currency": "TL",
"description": "Varyantlı Ürün Örneği",
"brand": "The North Face",
"desi": "1",
"source": "sopyo",
"tag_id": 453,
"category": {
"id": 413616,
"name": "Bot",
"status": false
},
"images": [
"https://app.sopyo.com/public/products/a3150a3c93a90eb882dbecb5e3d7f8f9.jpg",
"https://app.sopyo.com/public/products/9e15adb60acffcd98af06e02c7241a8a.jpg",
"https://app.sopyo.com/public/products/516c4c59ab7a0d900f402c9fb07ef96f.jpg",
"https://app.sopyo.com/public/products/ddd0d5d962f4dcf7ad0ac10c713f9fc4.jpg"
],
"variants": [
{
"id": 14824969,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WEY",
"stock": 0,
"barcode": "HBCV00002Z3WEY",
"option1": {
"name": "Ayakkabı Numarası",
"value": "40"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
},
{
"id": 14824972,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WEZ",
"stock": 0,
"barcode": "HBCV00002Z3WEZ",
"option1": {
"name": "Ayakkabı Numarası",
"value": "41"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
},
{
"id": 14824975,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WF0",
"stock": 0,
"barcode": "HBCV00002Z3WF0",
"option1": {
"name": "Ayakkabı Numarası",
"value": "42"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
]
}
]
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
"status": false,"message": "Unauthenticated."}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Ürün id'si
title
string
Ürün adı
sub_title
string
Ürün alt başlığı
stock
string
Ürün stok bilgisi
stock_code
string
Ürün stok kodu bilgisi
barcode
string
Ürün barkod bilgisi
barcode_2
string
Ürün ikinci barkod bilgisi
tax_rate
integer
Ürün KDV oranı bilgisi
currency
string
Ürün satış para birimi bilgisi
description
string
Ürün açıklaması
brand
string
Ürün marka bilgisi
desi
string
Ürün desi bilgisi
source
string
Ürünün hangi kaynak üzerinden sisteme eklendiği bilgisini vermektedir
category
object
Ürünün kategori bilgisini vermektedir
images
array
Ürün resimlerinin URL adres bilgilerini vermektedir.
variants
array
Ürün varyantlarını vermektedir.
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Göster
Kimlik doğrulama gerektirir
Ürün Kaydı Göster
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/products/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/products/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"id": 18248770,
"title": "Varyantlı Ürün Örneği",
"sub_title": "",
"stock": 0,
"stock_code": "HBCV00002Z3YQM",
"barcode": "8683323005482",
"barcode_2": null,
"tax_rate": 8,
"currency": "TL",
"description": "Varyantlı Ürün Örneği",
"brand": "The North Face",
"desi": "1",
"source": "sopyo",
"tag_id": 453,
"category": {
"id": 413616,
"name": "Bot",
"status": false
},
"images": [
"https://app.sopyo.com/public/products/a3150a3c93a90eb882dbecb5e3d7f8f9.jpg",
"https://app.sopyo.com/public/products/9e15adb60acffcd98af06e02c7241a8a.jpg",
"https://app.sopyo.com/public/products/516c4c59ab7a0d900f402c9fb07ef96f.jpg",
"https://app.sopyo.com/public/products/ddd0d5d962f4dcf7ad0ac10c713f9fc4.jpg"
],
"variants": [
{
"id": 14824969,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WEY",
"stock": 0,
"barcode": "HBCV00002Z3WEY",
"option1": {
"name": "Ayakkabı Numarası",
"value": "40"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
},
{
"id": 14824972,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WEZ",
"stock": 0,
"barcode": "HBCV00002Z3WEZ",
"option1": {
"name": "Ayakkabı Numarası",
"value": "41"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
},
{
"id": 14824975,
"product_id": 18248770,
"stock_code": "HBCV00002Z3WF0",
"stock": 0,
"barcode": "HBCV00002Z3WF0",
"option1": {
"name": "Ayakkabı Numarası",
"value": "42"
},
"option2": {
"name": "Renk",
"value": "Siyah - Sarı"
},
"price_1": {
"sale_price": 6555,
"list_price": null
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
]
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Ürün id'si
title
string
Ürün adı
sub_title
string
Ürün alt başlığı
stock
string
Ürün stok bilgisi
stock_code
string
Ürün stok kodu bilgisi
barcode
string
Ürün barkod bilgisi
barcode_2
string
Ürün ikinci barkod bilgisi
tax_rate
integer
Ürün KDV oranı bilgisi
currency
string
Ürün satış para birimi bilgisi
description
string
Ürün açıklaması
brand
string
Ürün marka bilgisi
desi
string
Ürün desi bilgisi
source
string
Ürünün hangi kaynak üzerinden sisteme eklendiği bilgisini vermektedir
category
object
Ürünün kategori bilgisini vermektedir
images
array
Ürün resimlerinin URL adres bilgilerini vermektedir.
variants
array
Ürün varyantlarını vermektedir.
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Güncelle
Kimlik doğrulama gerektirir
Ürün Kaydı Güncelle
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/products/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Çamaşır Mandalı\",
\"stock_code\": \"87484554\",
\"stock\": 45,
\"category_id\": 25,
\"desi\": 5,
\"tax_rate\": 18,
\"sub_title\": \"Gökkuşağı temalı çamaşır mandalı\",
\"barcode\": \"5EASDF522\",
\"barcode_2\": \"5EAEF525\",
\"brand\": \"YILDIZ\",
\"description\": \"Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.\",
\"images\": [
\"https:\\/\\/app.sopyo.com\\/public\\/2021\\/11\\/MANDAL-GOKKUSAGI-1.jpg\",
\"https:\\/\\/app.sopyo.com\\/public\\/2021\\/11\\/MANDAL-GOKKUSAGI-1.jpg\"
],
\"price1\": [
{
\"sale_price\": \"7913.34\",
\"list_price\": \"19.7\"
}
],
\"price2\": [
{
\"sale_price\": \"779429\",
\"list_price\": \"1\"
}
],
\"price3\": [
{
\"sale_price\": \"4\",
\"list_price\": \"4\"
}
],
\"price4\": [
{
\"sale_price\": \"2\",
\"list_price\": \"00\"
}
],
\"price5\": [
{
\"sale_price\": \"493\"
}
],
\"price6\": [
{
\"list_price\": \"994721.68\"
}
],
\"price7\": [
{
\"sale_price\": \"029714.4\",
\"list_price\": \"77\"
}
],
\"price8\": [
{
\"sale_price\": \"111\",
\"list_price\": \"0.15\"
}
],
\"price9\": [
{
\"sale_price\": \"893.54\",
\"list_price\": \"3\"
}
],
\"price10\": [
{
\"sale_price\": \"3628\",
\"list_price\": \"73182.05\"
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Çamaşır Mandalı",
"stock_code": "87484554",
"stock": 45,
"category_id": 25,
"desi": 5,
"tax_rate": 18,
"sub_title": "Gökkuşağı temalı çamaşır mandalı",
"barcode": "5EASDF522",
"barcode_2": "5EAEF525",
"brand": "YILDIZ",
"description": "Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.",
"images": [
"https:\/\/app.sopyo.com\/public\/2021\/11\/MANDAL-GOKKUSAGI-1.jpg",
"https:\/\/app.sopyo.com\/public\/2021\/11\/MANDAL-GOKKUSAGI-1.jpg"
],
"price1": [
{
"sale_price": "7913.34",
"list_price": "19.7"
}
],
"price2": [
{
"sale_price": "779429",
"list_price": "1"
}
],
"price3": [
{
"sale_price": "4",
"list_price": "4"
}
],
"price4": [
{
"sale_price": "2",
"list_price": "00"
}
],
"price5": [
{
"sale_price": "493"
}
],
"price6": [
{
"list_price": "994721.68"
}
],
"price7": [
{
"sale_price": "029714.4",
"list_price": "77"
}
],
"price8": [
{
"sale_price": "111",
"list_price": "0.15"
}
],
"price9": [
{
"sale_price": "893.54",
"list_price": "3"
}
],
"price10": [
{
"sale_price": "3628",
"list_price": "73182.05"
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/products/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'title' => 'Çamaşır Mandalı',
'stock_code' => '87484554',
'stock' => 45,
'category_id' => 25,
'desi' => 5.0,
'tax_rate' => 18.0,
'sub_title' => 'Gökkuşağı temalı çamaşır mandalı',
'barcode' => '5EASDF522',
'barcode_2' => '5EAEF525',
'brand' => 'YILDIZ',
'description' => 'Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.',
'images' => [
'https://app.sopyo.com/public/2021/11/MANDAL-GOKKUSAGI-1.jpg',
'https://app.sopyo.com/public/2021/11/MANDAL-GOKKUSAGI-1.jpg',
],
'price1' => [
[
'sale_price' => '7913.34',
'list_price' => '19.7',
],
],
'price2' => [
[
'sale_price' => '779429',
'list_price' => '1',
],
],
'price3' => [
[
'sale_price' => '4',
'list_price' => '4',
],
],
'price4' => [
[
'sale_price' => '2',
'list_price' => '00',
],
],
'price5' => [
[
'sale_price' => '493',
],
],
'price6' => [
[
'list_price' => '994721.68',
],
],
'price7' => [
[
'sale_price' => '029714.4',
'list_price' => '77',
],
],
'price8' => [
[
'sale_price' => '111',
'list_price' => '0.15',
],
],
'price9' => [
[
'sale_price' => '893.54',
'list_price' => '3',
],
],
'price10' => [
[
'sale_price' => '3628',
'list_price' => '73182.05',
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/5'
payload = {
"title": "Çamaşır Mandalı",
"stock_code": "87484554",
"stock": 45,
"category_id": 25,
"desi": 5,
"tax_rate": 18,
"sub_title": "Gökkuşağı temalı çamaşır mandalı",
"barcode": "5EASDF522",
"barcode_2": "5EAEF525",
"brand": "YILDIZ",
"description": "Gökkuşağı temalı çamaşır mandalları kaliteli malzeme yapısı ile uzun süre kullanılabilir.",
"images": [
"https:\/\/app.sopyo.com\/public\/2021\/11\/MANDAL-GOKKUSAGI-1.jpg",
"https:\/\/app.sopyo.com\/public\/2021\/11\/MANDAL-GOKKUSAGI-1.jpg"
],
"price1": [
{
"sale_price": "7913.34",
"list_price": "19.7"
}
],
"price2": [
{
"sale_price": "779429",
"list_price": "1"
}
],
"price3": [
{
"sale_price": "4",
"list_price": "4"
}
],
"price4": [
{
"sale_price": "2",
"list_price": "00"
}
],
"price5": [
{
"sale_price": "493"
}
],
"price6": [
{
"list_price": "994721.68"
}
],
"price7": [
{
"sale_price": "029714.4",
"list_price": "77"
}
],
"price8": [
{
"sale_price": "111",
"list_price": "0.15"
}
],
"price9": [
{
"sale_price": "893.54",
"list_price": "3"
}
],
"price10": [
{
"sale_price": "3628",
"list_price": "73182.05"
}
]
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"id": 1,
"title": "Sırt Çantası",
"sub_title": null,
"stock": 50,
"stock_code": "SPE80693",
"barcode": "1234556",
"barcode_2": null,
"tax_rate": 18,
"currency": "TL",
"description": "",
"brand": "Sopyo",
"desi": "1",
"source": "ankasync",
"price_1": {
"sale_price": 681.08,
"list_price": 690.08
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null,
"category": {
"id": 1,
"name": "Çanta",
"status": false
},
"images": [
"https://www.app.sopyo.com/images/urunler/sirt-can-5253_1.jpg"
],
"variants": []
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
"status": false,"message": "Unauthenticated."}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Ürün id'si
title
string
Ürün adı
sub_title
string
Ürün alt başlığı
stock
string
Ürün stok bilgisi
stock_code
string
Ürün stok kodu bilgisi
barcode
string
Ürün barkod bilgisi
barcode_2
string
Ürün ikinci barkod bilgisi
tax_rate
integer
Ürün KDV oranı bilgisi
currency
string
Ürün satış para birimi bilgisi
description
string
Ürün açıklaması
brand
string
Ürün marka bilgisi
desi
string
Ürün desi bilgisi
source
string
Ürünün hangi kaynak üzerinden sisteme eklendiği bilgisini vermektedir
category
object
Ürünün kategori bilgisini vermektedir
images
array
Ürün resimlerinin URL adres bilgilerini vermektedir.
variants
array
Ürün varyantlarını vermektedir.
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Sil
Kimlik doğrulama gerektirir
Ürün Kaydı Sil
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/products/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/products/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Ürün Seçenek Listesi (Varyant)
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/products/1/variants" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/1/variants"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/products/1/variants',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/1/variants'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 21,
"product_id": 2,
"stock_code": "hgfkzm1-1063-020beyazl",
"stock": 50,
"barcode": "",
"option1": {
"name": "Renk",
"value": "Beyaz"
},
"option2": {
"name": "Beden",
"value": "L"
},
"price_1": {
"sale_price": 0,
"list_price": 0
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
],
"links": {
"first": "/api/v2/products/2/variants?page=1",
"last": "/api/v2/products/2/variants?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "/api/v2/products/2/variants?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Sonraki »",
"active": false
}
],
"path": "/api/v2/products/2/variants",
"per_page": 100,
"to": 3,
"total": 3
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Varyant id'si
product_id
integer
Ürün id'si
stock_code
string
Varyant stok kodu bilgisi
stock
number
Varyant stok bilgisi
barcode
string
Varyant barkod bilgisi
Varyant seçenek bilgisi
Varyant seçenek adı
option1
object
option1.name
string
option1.value
string
Varyant seçenek değeri
Varyant seçenek bilgisi
Varyant seçenek adı
option2
object
option2.name
string
option2.value
string
Varyant seçenek değeri
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Seçenek Ekle (Varyant)
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/products/1/variants" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"stock_code\": \"qui\",
\"stock\": 3,
\"barcode\": \"voluptates\",
\"values\": [
{
\"name\": \"voluptates\",
\"value\": \"corrupti\"
}
],
\"price_1\": [
{
\"sale_price\": \"1643\",
\"list_price\": \"3.35\"
}
],
\"price_2\": [
{
\"sale_price\": \"715\",
\"list_price\": \"0331797.4\"
}
],
\"price_3\": [
{
\"sale_price\": \"048\",
\"list_price\": \"404.54\"
}
],
\"price_4\": [
{
\"sale_price\": \"2257\",
\"list_price\": \"610\"
}
],
\"price_5\": [
{
\"sale_price\": \"53\",
\"list_price\": \"9\"
}
],
\"price_6\": [
{
\"sale_price\": \"232957478\",
\"list_price\": \"363238.31\"
}
],
\"price_7\": [
{
\"sale_price\": \"84\",
\"list_price\": \"5\"
}
],
\"price_8\": [
{
\"sale_price\": \"1946042.8\",
\"list_price\": \"6944\"
}
],
\"price_9\": [
{
\"sale_price\": \"2.74\",
\"list_price\": \"4890.2\"
}
],
\"price_10\": [
{
\"sale_price\": \"2.48\",
\"list_price\": \"3.33\"
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/1/variants"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"stock_code": "qui",
"stock": 3,
"barcode": "voluptates",
"values": [
{
"name": "voluptates",
"value": "corrupti"
}
],
"price_1": [
{
"sale_price": "1643",
"list_price": "3.35"
}
],
"price_2": [
{
"sale_price": "715",
"list_price": "0331797.4"
}
],
"price_3": [
{
"sale_price": "048",
"list_price": "404.54"
}
],
"price_4": [
{
"sale_price": "2257",
"list_price": "610"
}
],
"price_5": [
{
"sale_price": "53",
"list_price": "9"
}
],
"price_6": [
{
"sale_price": "232957478",
"list_price": "363238.31"
}
],
"price_7": [
{
"sale_price": "84",
"list_price": "5"
}
],
"price_8": [
{
"sale_price": "1946042.8",
"list_price": "6944"
}
],
"price_9": [
{
"sale_price": "2.74",
"list_price": "4890.2"
}
],
"price_10": [
{
"sale_price": "2.48",
"list_price": "3.33"
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/products/1/variants',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'stock_code' => 'qui',
'stock' => 3,
'barcode' => 'voluptates',
'values' => [
[
'name' => 'voluptates',
'value' => 'corrupti',
],
],
'price_1' => [
[
'sale_price' => '1643',
'list_price' => '3.35',
],
],
'price_2' => [
[
'sale_price' => '715',
'list_price' => '0331797.4',
],
],
'price_3' => [
[
'sale_price' => '048',
'list_price' => '404.54',
],
],
'price_4' => [
[
'sale_price' => '2257',
'list_price' => '610',
],
],
'price_5' => [
[
'sale_price' => '53',
'list_price' => '9',
],
],
'price_6' => [
[
'sale_price' => '232957478',
'list_price' => '363238.31',
],
],
'price_7' => [
[
'sale_price' => '84',
'list_price' => '5',
],
],
'price_8' => [
[
'sale_price' => '1946042.8',
'list_price' => '6944',
],
],
'price_9' => [
[
'sale_price' => '2.74',
'list_price' => '4890.2',
],
],
'price_10' => [
[
'sale_price' => '2.48',
'list_price' => '3.33',
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/1/variants'
payload = {
"stock_code": "qui",
"stock": 3,
"barcode": "voluptates",
"values": [
{
"name": "voluptates",
"value": "corrupti"
}
],
"price_1": [
{
"sale_price": "1643",
"list_price": "3.35"
}
],
"price_2": [
{
"sale_price": "715",
"list_price": "0331797.4"
}
],
"price_3": [
{
"sale_price": "048",
"list_price": "404.54"
}
],
"price_4": [
{
"sale_price": "2257",
"list_price": "610"
}
],
"price_5": [
{
"sale_price": "53",
"list_price": "9"
}
],
"price_6": [
{
"sale_price": "232957478",
"list_price": "363238.31"
}
],
"price_7": [
{
"sale_price": "84",
"list_price": "5"
}
],
"price_8": [
{
"sale_price": "1946042.8",
"list_price": "6944"
}
],
"price_9": [
{
"sale_price": "2.74",
"list_price": "4890.2"
}
],
"price_10": [
{
"sale_price": "2.48",
"list_price": "3.33"
}
]
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 21,
"product_id": 2,
"stock_code": "hgfkzm1-1063-020beyazl",
"stock": 50,
"barcode": "",
"option1": {
"name": "Renk",
"value": "Beyaz"
},
"option2": {
"name": "Beden",
"value": "L"
},
"price_1": {
"sale_price": 0,
"list_price": 0
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Varyant id'si
product_id
integer
Ürün id'si
stock_code
string
Varyant stok kodu bilgisi
stock
number
Varyant stok bilgisi
barcode
string
Varyant barkod bilgisi
Varyant seçenek bilgisi
Varyant seçenek adı
option1
object
option1.name
string
option1.value
string
Varyant seçenek değeri
Varyant seçenek bilgisi
Varyant seçenek adı
option2
object
option2.name
string
option2.value
string
Varyant seçenek değeri
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Seçenek Göster (Varyant)
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/products/13/variants/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/13/variants/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/products/13/variants/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/13/variants/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 21,
"product_id": 2,
"stock_code": "hgfkzm1-1063-020beyazl",
"stock": 50,
"barcode": "",
"option1": {
"name": "Renk",
"value": "Beyaz"
},
"option2": {
"name": "Beden",
"value": "L"
},
"price_1": {
"sale_price": 0,
"list_price": 0
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Varyant id'si
product_id
integer
Ürün id'si
stock_code
string
Varyant stok kodu bilgisi
stock
number
Varyant stok bilgisi
barcode
string
Varyant barkod bilgisi
Varyant seçenek bilgisi
Varyant seçenek adı
option1
object
option1.name
string
option1.value
string
Varyant seçenek değeri
Varyant seçenek bilgisi
Varyant seçenek adı
option2
object
option2.name
string
option2.value
string
Varyant seçenek değeri
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Seçenek Güncelle (Varyant)
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/products/2/variants/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"stock_code\": \"animi\",
\"stock\": 5,
\"barcode\": \"quae\",
\"values\": [
{
\"name\": \"et\",
\"value\": \"repellendus\"
}
],
\"price_1\": [
{
\"sale_price\": \"7178923.84\",
\"list_price\": \"078547.10\"
}
],
\"price_2\": [
{
\"sale_price\": \"8\",
\"list_price\": \"30680.32\"
}
],
\"price_3\": [
{
\"sale_price\": \"42\",
\"list_price\": \"447.3\"
}
],
\"price_4\": [
{
\"sale_price\": \"79\",
\"list_price\": \"31590247.19\"
}
],
\"price_5\": [
{
\"sale_price\": \"00\",
\"list_price\": \"10\"
}
],
\"price_6\": [
{
\"sale_price\": \"1.31\",
\"list_price\": \"1.82\"
}
],
\"price_7\": [
{
\"sale_price\": \"09.07\",
\"list_price\": \"1328016\"
}
],
\"price_8\": [
{
\"sale_price\": \"172750.9\",
\"list_price\": \"8.12\"
}
],
\"price_9\": [
{
\"sale_price\": \"1.3\",
\"list_price\": \"71600\"
}
],
\"price_10\": [
{
\"sale_price\": \"000975.5\",
\"list_price\": \"4\"
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/2/variants/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"stock_code": "animi",
"stock": 5,
"barcode": "quae",
"values": [
{
"name": "et",
"value": "repellendus"
}
],
"price_1": [
{
"sale_price": "7178923.84",
"list_price": "078547.10"
}
],
"price_2": [
{
"sale_price": "8",
"list_price": "30680.32"
}
],
"price_3": [
{
"sale_price": "42",
"list_price": "447.3"
}
],
"price_4": [
{
"sale_price": "79",
"list_price": "31590247.19"
}
],
"price_5": [
{
"sale_price": "00",
"list_price": "10"
}
],
"price_6": [
{
"sale_price": "1.31",
"list_price": "1.82"
}
],
"price_7": [
{
"sale_price": "09.07",
"list_price": "1328016"
}
],
"price_8": [
{
"sale_price": "172750.9",
"list_price": "8.12"
}
],
"price_9": [
{
"sale_price": "1.3",
"list_price": "71600"
}
],
"price_10": [
{
"sale_price": "000975.5",
"list_price": "4"
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/products/2/variants/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'stock_code' => 'animi',
'stock' => 5,
'barcode' => 'quae',
'values' => [
[
'name' => 'et',
'value' => 'repellendus',
],
],
'price_1' => [
[
'sale_price' => '7178923.84',
'list_price' => '078547.10',
],
],
'price_2' => [
[
'sale_price' => '8',
'list_price' => '30680.32',
],
],
'price_3' => [
[
'sale_price' => '42',
'list_price' => '447.3',
],
],
'price_4' => [
[
'sale_price' => '79',
'list_price' => '31590247.19',
],
],
'price_5' => [
[
'sale_price' => '00',
'list_price' => '10',
],
],
'price_6' => [
[
'sale_price' => '1.31',
'list_price' => '1.82',
],
],
'price_7' => [
[
'sale_price' => '09.07',
'list_price' => '1328016',
],
],
'price_8' => [
[
'sale_price' => '172750.9',
'list_price' => '8.12',
],
],
'price_9' => [
[
'sale_price' => '1.3',
'list_price' => '71600',
],
],
'price_10' => [
[
'sale_price' => '000975.5',
'list_price' => '4',
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/2/variants/1'
payload = {
"stock_code": "animi",
"stock": 5,
"barcode": "quae",
"values": [
{
"name": "et",
"value": "repellendus"
}
],
"price_1": [
{
"sale_price": "7178923.84",
"list_price": "078547.10"
}
],
"price_2": [
{
"sale_price": "8",
"list_price": "30680.32"
}
],
"price_3": [
{
"sale_price": "42",
"list_price": "447.3"
}
],
"price_4": [
{
"sale_price": "79",
"list_price": "31590247.19"
}
],
"price_5": [
{
"sale_price": "00",
"list_price": "10"
}
],
"price_6": [
{
"sale_price": "1.31",
"list_price": "1.82"
}
],
"price_7": [
{
"sale_price": "09.07",
"list_price": "1328016"
}
],
"price_8": [
{
"sale_price": "172750.9",
"list_price": "8.12"
}
],
"price_9": [
{
"sale_price": "1.3",
"list_price": "71600"
}
],
"price_10": [
{
"sale_price": "000975.5",
"list_price": "4"
}
]
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 21,
"product_id": 2,
"stock_code": "hgfkzm1-1063-020beyazl",
"stock": 50,
"barcode": "",
"option1": {
"name": "Renk",
"value": "Beyaz"
},
"option2": {
"name": "Beden",
"value": "L"
},
"price_1": {
"sale_price": 0,
"list_price": 0
},
"price_2": null,
"price_3": null,
"price_4": null,
"price_5": null,
"price_6": null,
"price_7": null,
"price_8": null,
"price_9": null,
"price_10": null
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Varyant id'si
product_id
integer
Ürün id'si
stock_code
string
Varyant stok kodu bilgisi
stock
number
Varyant stok bilgisi
barcode
string
Varyant barkod bilgisi
Varyant seçenek bilgisi
Varyant seçenek adı
option1
object
option1.name
string
option1.value
string
Varyant seçenek değeri
Varyant seçenek bilgisi
Varyant seçenek adı
option2
object
option2.name
string
option2.value
string
Varyant seçenek değeri
Fiyat 1 grubunun fiyat bilgisini vermektedir
Fiyat 1 grubunun satış fiyatı bilgisini vermektedir
price_1
object
price_1.sale_price
decimal
price_1.list_price
decimal
Fiyat 1 grubunun liste fiyatı bilgisini vermektedir
Fiyat 2 grubunun fiyat bilgisini vermektedir
Fiyat 2 grubunun satış fiyatı bilgisini vermektedir
price_2
object
price_2.sale_price
decimal
price_2.list_price
decimal
Fiyat 2 grubunun liste fiyatı bilgisini vermektedir
Fiyat 3 grubunun fiyat bilgisini vermektedir
Fiyat 3 grubunun satış fiyatı bilgisini vermektedir
price_3
object
price_3.sale_price
decimal
price_3.list_price
decimal
Fiyat 3 grubunun liste fiyatı bilgisini vermektedir
Fiyat 4 grubunun fiyat bilgisini vermektedir
Fiyat 4 grubunun satış fiyatı bilgisini vermektedir
price_4
object
price_4.sale_price
decimal
price_4.list_price
decimal
Fiyat 4 grubunun liste fiyatı bilgisini vermektedir
Fiyat 5 grubunun fiyat bilgisini vermektedir
Fiyat 5 grubunun satış fiyatı bilgisini vermektedir
price_5
object
price_5.sale_price
decimal
price_5.list_price
decimal
Fiyat 5 grubunun liste fiyatı bilgisini vermektedir
Fiyat 6 grubunun fiyat bilgisini vermektedir
Fiyat 6 grubunun satış fiyatı bilgisini vermektedir
price_6
object
price_6.sale_price
decimal
price_6.list_price
decimal
Fiyat 6 grubunun liste fiyatı bilgisini vermektedir
Fiyat 7 grubunun fiyat bilgisini vermektedir
Fiyat 7 grubunun satış fiyatı bilgisini vermektedir
price_7
object
price_7.sale_price
decimal
price_7.list_price
decimal
Fiyat 7 grubunun liste fiyatı bilgisini vermektedir
Fiyat 8 grubunun fiyat bilgisini vermektedir
Fiyat 8 grubunun satış fiyatı bilgisini vermektedir
price_8
object
price_8.sale_price
decimal
price_8.list_price
decimal
Fiyat 8 grubunun liste fiyatı bilgisini vermektedir
Fiyat 9 grubunun fiyat bilgisini vermektedir
Fiyat 9 grubunun satış fiyatı bilgisini vermektedir
price_9
object
price_9.sale_price
decimal
price_9.list_price
decimal
Fiyat 9 grubunun liste fiyatı bilgisini vermektedir
Fiyat 10 grubunun fiyat bilgisini vermektedir
Fiyat 10 grubunun satış fiyatı bilgisini vermektedir
price_10
object
price_10.sale_price
decimal
price_10.list_price
decimal
Fiyat 10 grubunun liste fiyatı bilgisini vermektedir
Ürün Seçenek Sil (Varyant)
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/products/2/variants/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/2/variants/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/products/2/variants/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/2/variants/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Ürün Resimleri
Kimlik doğrulama gerektirir
Ürün Resimleri
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/products/5/images" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/products/5/images"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/products/5/images',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/products/5/images'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
"https://www.app.sopyo.com/images/urunler/sirt-can-5253_1.jpg",
"https://www.app.sopyo.com/images/urunler/sirt-can-5253_2.jpg"
]
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Kategori Yönetimi
Kategori ile alakalı tüm işlemleri bu alanda yapabilirsiniz
Kategori Listesi
Kimlik doğrulama gerektirir
Kategori Listesi
// Örnek filtrelemeler
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/categories" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/categories"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/categories',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/categories'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 1,
"name": "Telefon"
},
{
"id": 2,
"name": "Televizyon"
}
],
"links": {
"first": "/api/v2/categories?page=1",
"last": "/api/v2/categories?page=2",
"prev": null,
"next": "/api/v2/categories?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 2,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "/api/v2/categories?page=1",
"label": "1",
"active": true
},
{
"url": "/api/v2/categories?page=2",
"label": "2",
"active": false
},
{
"url": "/api/v2/categories?page=2",
"label": "Sonraki »",
"active": false
}
],
"path": "/api/v2/categories",
"per_page": 100,
"to": 100,
"total": 124
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Marka id'si
name
string
Marka adı
Kategori Ekle
Kimlik doğrulama gerektirir
Yeni kategori kaydı oluştur
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/categories" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Televizyon\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/categories"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Televizyon"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/categories',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Televizyon',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/categories'
payload = {
"name": "Televizyon"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Televizyon"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Kategori id'si
name
string
Kategori adı
Kategori Göster
Kimlik doğrulama gerektirir
Kategori Kaydı Göster
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/categories/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/categories/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/categories/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/categories/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Televizyon"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Kategori id'si
name
string
Kategori adı
Kategori Güncelle
Kimlik doğrulama gerektirir
Kategori Kaydı Güncelle
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/categories/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Televizyon\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/categories/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Televizyon"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/categories/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Televizyon',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/categories/5'
payload = {
"name": "Televizyon"
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Apple"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Kategori id'si
name
string
Kategori adı
Kategori Sil
Kimlik doğrulama gerektirir
Kategori Kaydı Sil
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/categories/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/categories/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/categories/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/categories/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Marka Yönetimi
Marka ile alakalı tüm işlemleri bu alanda yapabilirsiniz
Marka Listesi
Kimlik doğrulama gerektirir
Marka Listesi
// Örnek filtrelemeler
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/brands" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/brands"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/brands',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/brands'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 1,
"name": "Sopyo"
},
{
"id": 2,
"name": "diğer"
}
],
"links": {
"first": "/api/v2/brands?page=1",
"last": "/api/v2/brands?page=2",
"prev": null,
"next": "/api/v2/brands?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 2,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "/api/v2/brands?page=1",
"label": "1",
"active": true
},
{
"url": "/api/v2/brands?page=2",
"label": "2",
"active": false
},
{
"url": "/api/v2/brands?page=2",
"label": "Sonraki »",
"active": false
}
],
"path": "/api/v2/brands",
"per_page": 100,
"to": 100,
"total": 124
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Marka id'si
name
string
Marka adı
Marka Ekle
Kimlik doğrulama gerektirir
Yeni marka kaydı oluştur
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/brands" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Apple\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/brands"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Apple"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/brands',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Apple',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/brands'
payload = {
"name": "Apple"
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Apple"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
Received response:
Request failed with error:
Response
Response Fields
id
integer
Marka id'si
name
string
Marka adı
Marka Göster
Kimlik doğrulama gerektirir
Marka Kaydı Göster
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/brands/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/brands/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/brands/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/brands/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Apple"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Marka id'si
name
string
Marka adı
Marka Güncelle
Kimlik doğrulama gerektirir
Marka Kaydı Güncelle
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/brands/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Samsung\"
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/brands/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Samsung"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/brands/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'name' => 'Samsung',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/brands/5'
payload = {
"name": "Samsung"
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 5,
"name": "Apple"
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
integer
Marka id'si
name
string
Marka adı
Marka Sil
Kimlik doğrulama gerektirir
Marka Kaydı Sil
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/brands/5" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/brands/5"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/brands/5',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/brands/5'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Etiket Yönetimi
Ürün etiket işlemlerini bu bölümde yapabilirsiniz.
Etiket Listesi
Kimlik doğrulama gerektirir
Etiket Listesi
Response
Response Fields
id
integer
Etiket id'si
name
string
Etiket adı
color
string
Etiket renk kodu
Etiket Ekle
Kimlik doğrulama gerektirir
Yeni etiket kaydı oluştur
Response
Response Fields
id
integer
Etiket id'si
name
string
Etiket adı
color
string
Etiket renk kodu
Etiket Göster
Kimlik doğrulama gerektirir
Etiket Kaydı Göster
Response
Response Fields
id
integer
Etiket id'si
name
string
Etiket adı
color
string
Etiket renk kodu
Etiket Güncelle
Kimlik doğrulama gerektirir
Etiket Kaydı Güncelle
Response
Response Fields
id
integer
Etiket id'si
name
string
Etiket adı
color
string
Etiket renk kodu
Etiket Sil
Kimlik doğrulama gerektirir
Etiket Kaydı Sil
Etiket'e Ürün Atama
Kimlik doğrulama gerektirir
Etikete Ürün Atama
Etiket'den Ürün Çıkartma
Kimlik doğrulama gerektirir
Etiket'den Ürün Çıkartma
Sipariş Yönetimi
Sipariş ile ilgili işlemleri bu bölümde yapabilirsiniz.
Sipariş Listesi
Kimlik doğrulama gerektirir
Sipariş Listesi
// Örnek filtrelemeler
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/orders" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/orders',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": [
{
"id": 111,
"order_code": "1277750982",
"order_type": "trendyol",
"order_date": "2022-08-26 20:50",
"order_status": 1,
"market_place_id": "55206377",
"commission_total": 0,
"total_price": 100000,
"customer_info": {
"email": "pf+7vw6nvnq@trendyolmail.com"
},
"shipping_info": {
"full_name": "Yasin AYDOĞDU",
"gsm": "1231231212",
"identification_no": "11111111111",
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": "Çifte Havuzlar, YTÜ Davutpaşa Kampüsü, Teknopark D:C1 Blok/205, 34220 Esenler/İstanbul Bina No:1 Daire:2 Esenler İstanbul Oms Address Description"
},
"billing_info": {
"full_name": "Proj-e Yazılım",
"gsm": "1231231212",
"identification_no": "11111111111",
"tax_number": "11111111111",
"tax_office": null,
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": null
},
"cargo_info": {
"company": null,
"type": "Satıcı Öder",
"campaing_no": "7250000006671572",
"tracking_no": null
},
"order_items": [
{
"marketplace_id": "4221437",
"marketplace_product_id": "194768909016",
"stock_code": "M520L11",
"product_name": "NB Performance Mens Shoes-Sonay",
"variant_stock_code": null,
"variant_name": null,
"commission_price": 0,
"quantity": 2,
"total_price": 100000
}
]
},
{
"id": 110,
"order_code": "1168935936",
"order_type": "trendyol",
"order_date": "2022-08-26 21:11",
"order_status": 1,
"market_place_id": "55206382",
"commission_total": 0,
"total_price": 1299,
"customer_info": {
"email": "pf+gllw353w@trendyolmail.com"
},
"shipping_info": {
"full_name": "Yasin AYDOĞDU",
"gsm": "1231231212",
"identification_no": "11111111111",
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": "Çifte Havuzlar, YTÜ Davutpaşa Kampüsü, Teknopark D:C1 Blok/205, 34220 Esenler/İstanbul Bina No:1 Daire:2 Esenler İstanbul Oms Address Description"
},
"billing_info": {
"full_name": "Proj-e Yazılım",
"gsm": "1231231212",
"identification_no": "11111111111",
"tax_number": "11111111111",
"tax_office": null,
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": null
},
"cargo_info": {
"company": null,
"type": "Satıcı Öder",
"campaing_no": "7250000006671626",
"tracking_no": null
},
"order_items": [
{
"marketplace_id": "4221440",
"marketplace_product_id": "194182165036",
"stock_code": "M520LN6",
"product_name": "New Balance 520",
"variant_stock_code": null,
"variant_name": null,
"commission_price": 0,
"quantity": 1,
"total_price": 1299
}
]
},
{
"id": 109,
"order_code": "730729781",
"order_type": "trendyol",
"order_date": "2022-08-26 21:22",
"order_status": 1,
"market_place_id": "55206384",
"commission_total": 0,
"total_price": 1299,
"customer_info": {
"email": "pf+de2j8m5l@trendyolmail.com"
},
"shipping_info": {
"full_name": "Yasin AYDOĞDU",
"gsm": "1231231212",
"identification_no": "11111111111",
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": "Çifte Havuzlar, YTÜ Davutpaşa Kampüsü, Teknopark D:C1 Blok/205, 34220 Esenler/İstanbul Bina No:1 Daire:2 Esenler İstanbul Oms Address Description"
},
"billing_info": {
"full_name": "Proj-e Yazılım",
"gsm": "1231231212",
"identification_no": "11111111111",
"tax_number": "11111111111",
"tax_office": null,
"city": "İstanbul",
"district": "Esenler",
"neighborhood": "Esenler",
"postal_code": "01010",
"address": null
},
"cargo_info": {
"company": null,
"type": "Satıcı Öder",
"campaing_no": "7250000006671640",
"tracking_no": null
},
"order_items": [
{
"marketplace_id": "4221441",
"marketplace_product_id": "194182165036",
"stock_code": "M520LN6",
"product_name": "New Balance 520",
"variant_stock_code": null,
"variant_name": null,
"commission_price": 0,
"quantity": 1,
"total_price": 1299
}
]
}
],
"links": {
"first": "/api/v2/orders?page=1",
"last": "/api/v2/orders?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Önceki",
"active": false
},
{
"url": "/api/v2/orders?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Sonraki »",
"active": false
}
],
"path": "/api/v2/orders",
"per_page": 100,
"to": 3,
"total": 3
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
int
Sipariş Id si
order_code
string
Sipariş kodu bilgisi vermektedir.
order_type
string
Sipariş tipi, Trendyol,Hepsiburada,N11 vs siparişin oluşturulduğu market bilgisini vermektedir.
order_status
string
Sipariş durumu bilgisini vermektedir.
Onay Bekleyen Siparişler 1
Onaylanan Siparişler 2
Kargolanan Siparişler 3
İptal Edilen Siparişler 4
market_place_id
string
Sipariş pazaryeri bilgisini vermektedir.
commission_total
decimal
Sipariş komisyon tutarı bilgisini vermektedir.
total_price
decimal
Siparişin toplam tutarı bilgisini vermektedir.
customer_info
object
Müşteri bilgisini vermektedir.
shipping_info
object
Siparişin teslimat adresi bilgilerini vermektedir..
billing_info
object
Siparişin faturalandırma bilgilerini vermektedir..
cargo_info
object
Siparişi kargo bilgilerini vermektedir.
order_items
object
Sipariş oluşturan ürünlerin bilgisini vermektedir vermektedir.
Sipariş Oluştur
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/orders" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"order_code\": null,
\"order_status\": null,
\"total_price\": null,
\"customer_info\": {
\"email\": null,
\"name\": null
},
\"shipping_info\": {
\"full_name\": null,
\"gsm\": null,
\"identification_no\": null,
\"city\": null,
\"district\": null,
\"neighborhood\": null,
\"address\": null
},
\"billing_info\": {
\"full_name\": null,
\"gsm\": null,
\"city\": null,
\"district\": null,
\"neighborhood\": null,
\"address\": null
},
\"order_items\": null
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"order_code": null,
"order_status": null,
"total_price": null,
"customer_info": {
"email": null,
"name": null
},
"shipping_info": {
"full_name": null,
"gsm": null,
"identification_no": null,
"city": null,
"district": null,
"neighborhood": null,
"address": null
},
"billing_info": {
"full_name": null,
"gsm": null,
"city": null,
"district": null,
"neighborhood": null,
"address": null
},
"order_items": null
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/orders',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'order_code' => null,
'order_status' => null,
'total_price' => null,
'customer_info' => [
'email' => null,
'name' => null,
],
'shipping_info' => [
'full_name' => null,
'gsm' => null,
'identification_no' => null,
'city' => null,
'district' => null,
'neighborhood' => null,
'address' => null,
],
'billing_info' => [
'full_name' => null,
'gsm' => null,
'city' => null,
'district' => null,
'neighborhood' => null,
'address' => null,
],
'order_items' => null,
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders'
payload = {
"order_code": null,
"order_status": null,
"total_price": null,
"customer_info": {
"email": null,
"name": null
},
"shipping_info": {
"full_name": null,
"gsm": null,
"identification_no": null,
"city": null,
"district": null,
"neighborhood": null,
"address": null
},
"billing_info": {
"full_name": null,
"gsm": null,
"city": null,
"district": null,
"neighborhood": null,
"address": null
},
"order_items": null
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 198,
"order_code": 881448484,
"order_type": "SOPYOAPI",
"order_date": "2022-11-10 12:34",
"order_status": 1,
"erp_transfer_status": 0,
"market_place_id": null,
"commission_total": 0,
"total_price": 0,
"customer_info": {
"id": 169,
"name": "Sinan Gülsever",
"email": "sinan@sopyo.com",
"phone": null,
"tax_no": null,
"tax_office": null
},
"shipping_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": "0525841",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": "Demirtaş",
"postal_code": null,
"address": "BURSA"
},
"billing_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": null,
"tax_number": 5588,
"tax_office": "Nilüfer",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": null,
"postal_code": null,
"address": "BURSA"
},
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
},
"order_items": [
{
"marketplace_id": null,
"marketplace_product_id": null,
"stock_code": "7070",
"product_name": "Test ürün",
"variant_stock_code": null,
"variant_name": null,
"commission_price": null,
"quantity": 1,
"total_price": 780
}
]
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Response
Response Fields
id
int
Sipariş Id si
order_code
string
Sipariş kodu bilgisi vermektedir.
order_type
string
Sipariş tipi, Trendyol,Hepsiburada,N11 vs siparişin oluşturulduğu market bilgisini vermektedir.
order_status
string
Sipariş durumu bilgisini vermektedir.
Onay Bekleyen Siparişler 1
Onaylanan Siparişler 2
Kargolanan Siparişler 3
İptal Edilen Siparişler 4
erp_transfer_status
number
Sipariş erp aktarım durumunu vermektedir.
Aktarılan 1
Aktarılmayan 0
market_place_id
string
Sipariş pazaryeri bilgisini vermektedir.
commission_total
decimal
Sipariş komisyon tutarı bilgisini vermektedir.
total_price
decimal
Siparişin toplam tutarı bilgisini vermektedir.
customer_info
object
Müşteri bilgisini vermektedir.
shipping_info
object
Siparişin teslimat adresi bilgilerini vermektedir..
billing_info
object
Siparişin faturalandırma bilgilerini vermektedir..
cargo_info
object
Siparişi kargo bilgilerini vermektedir.
order_items
object
Sipariş oluşturan ürünlerin bilgisini vermektedir vermektedir.
Sipariş Göster
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request GET \
--get "https://api.sopyo.dev/api/v2/orders/" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders/"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->get(
'https://api.sopyo.dev/api/v2/orders/',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders/'
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('GET', url, headers=headers)
response.json()
Örnek Servis Cevabı (201, İşlem Başarılı):
{
"data": {
"id": 198,
"order_code": 881448484,
"order_type": "SOPYOAPI",
"order_date": "2022-11-10 12:34",
"order_status": 1,
"market_place_id": null,
"commission_total": 0,
"total_price": 0,
"customer_info": {
"id": 169,
"name": "Sinan Gülsever",
"email": "sinan@sopyo.com",
"phone": null,
"tax_no": null,
"tax_office": null
},
"shipping_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": "0525841",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": "Demirtaş",
"postal_code": null,
"address": "BURSA"
},
"billing_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": null,
"tax_number": 5588,
"tax_office": "Nilüfer",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": null,
"postal_code": null,
"address": "BURSA"
},
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
},
"order_items": [
{
"marketplace_id": null,
"marketplace_product_id": null,
"stock_code": "7070",
"product_name": "Test ürün",
"variant_stock_code": null,
"variant_name": null,
"commission_price": null,
"quantity": 1,
"total_price": 780
}
]
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Response
Response Fields
id
int
Sipariş Id si
order_code
string
Sipariş kodu bilgisi vermektedir.
order_type
string
Sipariş tipi, Trendyol,Hepsiburada,N11 vs siparişin oluşturulduğu market bilgisini vermektedir.
order_status
string
Sipariş durumu bilgisini vermektedir.
Onay Bekleyen Siparişler 1
Onaylanan Siparişler 2
Kargolanan Siparişler 3
İptal Edilen Siparişler 4
market_place_id
string
Sipariş pazaryeri bilgisini vermektedir.
commission_total
decimal
Sipariş komisyon tutarı bilgisini vermektedir.
total_price
decimal
Siparişin toplam tutarı bilgisini vermektedir.
customer_info
object
Müşteri bilgisini vermektedir.
shipping_info
object
Siparişin teslimat adresi bilgilerini vermektedir..
billing_info
object
Siparişin faturalandırma bilgilerini vermektedir..
cargo_info
object
Siparişi kargo bilgilerini vermektedir.
order_items
object
Sipariş oluşturan ürünlerin bilgisini vermektedir vermektedir.
Siparişi Sipariş Kodu ile Güncelle
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/orders/orderCode/" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"cargo_info\": {
\"company\": null,
\"type\": null,
\"campaing_no\": null,
\"tracking_no\": null
}
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders/orderCode/"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/orders/orderCode/',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'cargo_info' => [
'company' => null,
'type' => null,
'campaing_no' => null,
'tracking_no' => null,
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders/orderCode/'
payload = {
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
}
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 198,
"order_code": 881448484,
"order_type": "SOPYOAPI",
"order_date": "2022-11-10 12:34",
"order_status": 1,
"market_place_id": null,
"commission_total": 0,
"total_price": 0,
"customer_info": {
"id": 169,
"name": "Sinan Gülsever",
"email": "sinan@sopyo.com",
"phone": null,
"tax_no": null,
"tax_office": null
},
"shipping_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": "0525841",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": "Demirtaş",
"postal_code": null,
"address": "BURSA"
},
"billing_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": null,
"tax_number": 5588,
"tax_office": "Nilüfer",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": null,
"postal_code": null,
"address": "BURSA"
},
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
},
"order_items": [
{
"marketplace_id": null,
"marketplace_product_id": null,
"stock_code": "7070",
"product_name": "Test ürün",
"variant_stock_code": null,
"variant_name": null,
"commission_price": null,
"quantity": 1,
"total_price": 780
}
]
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Not Found"
}
Received response:
Request failed with error:
Response
Response Fields
id
int
Sipariş Id si
order_code
string
Sipariş kodu bilgisi vermektedir.
erp_transfer_status
number
Sipariş erp aktarım durumu, 0,1 değerleri içermelidir
order_type
string
Sipariş tipi, Trendyol,Hepsiburada,N11 vs siparişin oluşturulduğu market bilgisini vermektedir.
order_status
string
Sipariş durumu bilgisini vermektedir.
Onay Bekleyen Siparişler 1
Onaylanan Siparişler 2
Kargolanan Siparişler 3
İptal Edilen Siparişler 4
market_place_id
string
Sipariş pazaryeri bilgisini vermektedir.
commission_total
decimal
Sipariş komisyon tutarı bilgisini vermektedir.
total_price
decimal
Siparişin toplam tutarı bilgisini vermektedir.
customer_info
object
Müşteri bilgisini vermektedir.
shipping_info
object
Siparişin teslimat adresi bilgilerini vermektedir..
billing_info
object
Siparişin faturalandırma bilgilerini vermektedir..
cargo_info
object
Siparişi kargo bilgilerini vermektedir.
order_items
object
Sipariş oluşturan ürünlerin bilgisini vermektedir vermektedir.
Siparişi Sipariş ID ile Güncelle
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request PUT \
"https://api.sopyo.dev/api/v2/orders/id/{id}" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"cargo_info\": {
\"company\": null,
\"type\": null,
\"campaing_no\": null,
\"tracking_no\": null
}
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders/id/{id}"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->put(
'https://api.sopyo.dev/api/v2/orders/id/{id}',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'cargo_info' => [
'company' => null,
'type' => null,
'campaing_no' => null,
'tracking_no' => null,
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders/id/{id}'
payload = {
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
}
}
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('PUT', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"data": {
"id": 198,
"order_code": 881448484,
"order_type": "SOPYOAPI",
"order_date": "2022-11-10 12:34",
"order_status": 1,
"market_place_id": null,
"commission_total": 0,
"total_price": 0,
"customer_info": {
"id": 169,
"name": "Sinan Gülsever",
"email": "sinan@sopyo.com",
"phone": null,
"tax_no": null,
"tax_office": null
},
"shipping_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": "0525841",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": "Demirtaş",
"postal_code": null,
"address": "BURSA"
},
"billing_info": {
"full_name": "Sinan Gülsever",
"gsm": "5346656326",
"identification_no": null,
"tax_number": 5588,
"tax_office": "Nilüfer",
"city": "BURSA",
"district": "Demirtaş",
"neighborhood": null,
"postal_code": null,
"address": "BURSA"
},
"cargo_info": {
"company": null,
"type": null,
"campaing_no": null,
"tracking_no": null
},
"order_items": [
{
"marketplace_id": null,
"marketplace_product_id": null,
"stock_code": "7070",
"product_name": "Test ürün",
"variant_stock_code": null,
"variant_name": null,
"commission_price": null,
"quantity": 1,
"total_price": 780
}
]
}
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Not Found"
}
Received response:
Request failed with error:
Response
Response Fields
id
int
Sipariş Id si
order_code
string
Sipariş kodu bilgisi vermektedir.
order_type
string
Sipariş tipi, Trendyol,Hepsiburada,N11 vs siparişin oluşturulduğu market bilgisini vermektedir.
order_status
string
Sipariş durumu bilgisini vermektedir.
Onay Bekleyen Siparişler 1
Onaylanan Siparişler 2
Kargolanan Siparişler 3
İptal Edilen Siparişler 4
market_place_id
string
Sipariş pazaryeri bilgisini vermektedir.
commission_total
decimal
Sipariş komisyon tutarı bilgisini vermektedir.
total_price
decimal
Siparişin toplam tutarı bilgisini vermektedir.
customer_info
object
Müşteri bilgisini vermektedir.
shipping_info
object
Siparişin teslimat adresi bilgilerini vermektedir..
billing_info
object
Siparişin faturalandırma bilgilerini vermektedir..
cargo_info
object
Siparişi kargo bilgilerini vermektedir.
order_items
object
Sipariş oluşturan ürünlerin bilgisini vermektedir vermektedir.
Sipariş Kaydı Sil
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request DELETE \
"https://api.sopyo.dev/api/v2/orders/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"
const url = new URL(
"https://api.sopyo.dev/api/v2/orders/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->delete(
'https://api.sopyo.dev/api/v2/orders/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('DELETE', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Sipariş Fatura İletimi
Kimlik doğrulama gerektirir
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/orders/sendOrderMarketPlace/1" \
--header "Authorization: Bearer {YOUR_AUTH_KEY}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
const url = new URL(
"https://api.sopyo.dev/api/v2/orders/sendOrderMarketPlace/1"
);
const headers = {
"Authorization": "Bearer {YOUR_AUTH_KEY}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/orders/sendOrderMarketPlace/1',
[
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_KEY}',
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/orders/sendOrderMarketPlace/1'
headers = {
'Authorization': 'Bearer {YOUR_AUTH_KEY}',
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers)
response.json()
Örnek Servis Cevabı (200, İşlem Başarılı):
{
"status": true,
"message": "İşlem başarılı"
}
Örnek Servis Cevabı (401, Kimlik Doğrulanmamış):
{
"status": false,
"message": "Unauthenticated."
}
Örnek Servis Cevabı (404, Kayıt Bulunamadı):
{
"status": false,
"message": "Kayıt Bulunamadı !"
}
Received response:
Request failed with error:
Stok & Fiyat Yönetimi
Stok ve Fiyat güncelleme işlemleri bu bölümde yapabilirsiniz.
Stok & Fiyat Güncelle
Kimlik doğrulama gerektirir
Stok ve fiyat güncelleme işlemi
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/process/price-and-stock" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"stock_code\": \"584854854\",
\"type\": \"product\",
\"stock\": 60,
\"price_1\": [
{
\"sale_price\": \"7\",
\"list_price\": \"3.31\"
}
],
\"price_2\": [
{
\"sale_price\": \"72810\",
\"list_price\": \"14586\"
}
],
\"price_3\": [
{
\"sale_price\": \"7.1\",
\"list_price\": \"0.27\"
}
],
\"price_4\": [
{
\"sale_price\": \"494\",
\"list_price\": \"83\"
}
],
\"price_5\": [
{
\"sale_price\": \"03\",
\"list_price\": \"3.6\"
}
],
\"price_6\": [
{
\"sale_price\": \"0.39\",
\"list_price\": \"4.40\"
}
],
\"price_7\": [
{
\"sale_price\": \"883537.9\",
\"list_price\": \"69770\"
}
],
\"price_8\": [
{
\"sale_price\": \"80.8\",
\"list_price\": \"74.7\"
}
],
\"price_9\": [
{
\"sale_price\": \"0391\",
\"list_price\": \"4\"
}
],
\"price_10\": [
{
\"sale_price\": \"71336328.3\",
\"list_price\": \"2\"
}
]
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/process/price-and-stock"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"stock": 60,
"price_1": [
{
"sale_price": "7",
"list_price": "3.31"
}
],
"price_2": [
{
"sale_price": "72810",
"list_price": "14586"
}
],
"price_3": [
{
"sale_price": "7.1",
"list_price": "0.27"
}
],
"price_4": [
{
"sale_price": "494",
"list_price": "83"
}
],
"price_5": [
{
"sale_price": "03",
"list_price": "3.6"
}
],
"price_6": [
{
"sale_price": "0.39",
"list_price": "4.40"
}
],
"price_7": [
{
"sale_price": "883537.9",
"list_price": "69770"
}
],
"price_8": [
{
"sale_price": "80.8",
"list_price": "74.7"
}
],
"price_9": [
{
"sale_price": "0391",
"list_price": "4"
}
],
"price_10": [
{
"sale_price": "71336328.3",
"list_price": "2"
}
]
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/process/price-and-stock',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'items' => [
[
'stock_code' => '584854854',
'type' => 'product',
'stock' => 60,
'price_1' => [
[
'sale_price' => '7',
'list_price' => '3.31',
],
],
'price_2' => [
[
'sale_price' => '72810',
'list_price' => '14586',
],
],
'price_3' => [
[
'sale_price' => '7.1',
'list_price' => '0.27',
],
],
'price_4' => [
[
'sale_price' => '494',
'list_price' => '83',
],
],
'price_5' => [
[
'sale_price' => '03',
'list_price' => '3.6',
],
],
'price_6' => [
[
'sale_price' => '0.39',
'list_price' => '4.40',
],
],
'price_7' => [
[
'sale_price' => '883537.9',
'list_price' => '69770',
],
],
'price_8' => [
[
'sale_price' => '80.8',
'list_price' => '74.7',
],
],
'price_9' => [
[
'sale_price' => '0391',
'list_price' => '4',
],
],
'price_10' => [
[
'sale_price' => '71336328.3',
'list_price' => '2',
],
],
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/process/price-and-stock'
payload = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"stock": 60,
"price_1": [
{
"sale_price": "7",
"list_price": "3.31"
}
],
"price_2": [
{
"sale_price": "72810",
"list_price": "14586"
}
],
"price_3": [
{
"sale_price": "7.1",
"list_price": "0.27"
}
],
"price_4": [
{
"sale_price": "494",
"list_price": "83"
}
],
"price_5": [
{
"sale_price": "03",
"list_price": "3.6"
}
],
"price_6": [
{
"sale_price": "0.39",
"list_price": "4.40"
}
],
"price_7": [
{
"sale_price": "883537.9",
"list_price": "69770"
}
],
"price_8": [
{
"sale_price": "80.8",
"list_price": "74.7"
}
],
"price_9": [
{
"sale_price": "0391",
"list_price": "4"
}
],
"price_10": [
{
"sale_price": "71336328.3",
"list_price": "2"
}
]
}
]
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, Ok):
{
"status": true,
"message": "",
"success": [],
"errors": [],
"success_count": 0,
"error_count": 0
}
Received response:
Request failed with error:
Response
Response Fields
success
object
Başarılı güncellemelerin stok kodu bilgisini vermektedir.
errors
object
Başarısız işlemleri, içerisinde stok kodu ve başarısız bilgi mesajı ile birlikte vermektedir.
success_count
integer
Başarılı olan işlemlerin toplam sayısını vermektedir.
errors
integer
Başarısız olan işlemlerini toplam sayısını vermektedir.
Fiyat Güncelle
Kimlik doğrulama gerektirir
Ürün ve varyant fiyat güncelleme işlemi
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/process/price" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"stock_code\": \"584854854\",
\"type\": \"product\",
\"price_1\": [
{
\"sale_price\": \"7\",
\"list_price\": \"3.31\"
}
],
\"price_2\": [
{
\"sale_price\": \"72810\",
\"list_price\": \"14586\"
}
],
\"price_3\": [
{
\"sale_price\": \"7.1\",
\"list_price\": \"0.27\"
}
],
\"price_4\": [
{
\"sale_price\": \"494\",
\"list_price\": \"83\"
}
],
\"price_5\": [
{
\"sale_price\": \"03\",
\"list_price\": \"3.6\"
}
],
\"price_6\": [
{
\"sale_price\": \"0.39\",
\"list_price\": \"4.40\"
}
],
\"price_7\": [
{
\"sale_price\": \"883537.9\",
\"list_price\": \"69770\"
}
],
\"price_8\": [
{
\"sale_price\": \"80.8\",
\"list_price\": \"74.7\"
}
],
\"price_9\": [
{
\"sale_price\": \"0391\",
\"list_price\": \"4\"
}
],
\"price_10\": [
{
\"sale_price\": \"71336328.3\",
\"list_price\": \"2\"
}
]
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/process/price"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"price_1": [
{
"sale_price": "7",
"list_price": "3.31"
}
],
"price_2": [
{
"sale_price": "72810",
"list_price": "14586"
}
],
"price_3": [
{
"sale_price": "7.1",
"list_price": "0.27"
}
],
"price_4": [
{
"sale_price": "494",
"list_price": "83"
}
],
"price_5": [
{
"sale_price": "03",
"list_price": "3.6"
}
],
"price_6": [
{
"sale_price": "0.39",
"list_price": "4.40"
}
],
"price_7": [
{
"sale_price": "883537.9",
"list_price": "69770"
}
],
"price_8": [
{
"sale_price": "80.8",
"list_price": "74.7"
}
],
"price_9": [
{
"sale_price": "0391",
"list_price": "4"
}
],
"price_10": [
{
"sale_price": "71336328.3",
"list_price": "2"
}
]
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/process/price',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'items' => [
[
'stock_code' => '584854854',
'type' => 'product',
'price_1' => [
[
'sale_price' => '7',
'list_price' => '3.31',
],
],
'price_2' => [
[
'sale_price' => '72810',
'list_price' => '14586',
],
],
'price_3' => [
[
'sale_price' => '7.1',
'list_price' => '0.27',
],
],
'price_4' => [
[
'sale_price' => '494',
'list_price' => '83',
],
],
'price_5' => [
[
'sale_price' => '03',
'list_price' => '3.6',
],
],
'price_6' => [
[
'sale_price' => '0.39',
'list_price' => '4.40',
],
],
'price_7' => [
[
'sale_price' => '883537.9',
'list_price' => '69770',
],
],
'price_8' => [
[
'sale_price' => '80.8',
'list_price' => '74.7',
],
],
'price_9' => [
[
'sale_price' => '0391',
'list_price' => '4',
],
],
'price_10' => [
[
'sale_price' => '71336328.3',
'list_price' => '2',
],
],
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/process/price'
payload = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"price_1": [
{
"sale_price": "7",
"list_price": "3.31"
}
],
"price_2": [
{
"sale_price": "72810",
"list_price": "14586"
}
],
"price_3": [
{
"sale_price": "7.1",
"list_price": "0.27"
}
],
"price_4": [
{
"sale_price": "494",
"list_price": "83"
}
],
"price_5": [
{
"sale_price": "03",
"list_price": "3.6"
}
],
"price_6": [
{
"sale_price": "0.39",
"list_price": "4.40"
}
],
"price_7": [
{
"sale_price": "883537.9",
"list_price": "69770"
}
],
"price_8": [
{
"sale_price": "80.8",
"list_price": "74.7"
}
],
"price_9": [
{
"sale_price": "0391",
"list_price": "4"
}
],
"price_10": [
{
"sale_price": "71336328.3",
"list_price": "2"
}
]
}
]
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, Ok):
{
"status": true,
"message": "",
"success": [],
"errors": [],
"success_count": 0,
"error_count": 0
}
Received response:
Request failed with error:
Response
Response Fields
success
object
Başarılı güncellemelerin stok kodu bilgisini vermektedir.
errors
object
Başarısız işlemleri, içerisinde stok kodu ve başarısız bilgi mesajı ile birlikte vermektedir.
success_count
integer
Başarılı olan işlemlerin toplam sayısını vermektedir.
errors
integer
Başarısız olan işlemlerini toplam sayısını vermektedir.
Stok Güncelle
Kimlik doğrulama gerektirir
Ürün ve varyant stok güncelleme işlemi
Örnek Servis İsteği:
curl --request POST \
"https://api.sopyo.dev/api/v2/process/stock" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"stock_code\": \"584854854\",
\"type\": \"product\",
\"stock\": 60
}
]
}"
const url = new URL(
"https://api.sopyo.dev/api/v2/process/stock"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"stock": 60
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());
$client = new \GuzzleHttp\Client();
$response = $client->post(
'https://api.sopyo.dev/api/v2/process/stock',
[
'headers' => [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
],
'json' => [
'items' => [
[
'stock_code' => '584854854',
'type' => 'product',
'stock' => 60,
],
],
],
]
);
$body = $response->getBody();
print_r(json_decode((string) $body));
import requests
import json
url = 'https://api.sopyo.dev/api/v2/process/stock'
payload = {
"items": [
{
"stock_code": "584854854",
"type": "product",
"stock": 60
}
]
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
response = requests.request('POST', url, headers=headers, json=payload)
response.json()
Örnek Servis Cevabı (200, Ok):
{
"status": true,
"message": "",
"success": [],
"errors": [],
"success_count": 0,
"error_count": 0
}
Received response:
Request failed with error:
Response
Response Fields
success
object
Başarılı güncellemelerin stok kodu bilgisini vermektedir.
errors
object
Başarısız işlemleri, içerisinde stok kodu ve başarısız bilgi mesajı ile birlikte vermektedir.
success_count
integer
Başarılı olan işlemlerin toplam sayısını vermektedir.
errors
integer
Başarısız olan işlemlerini toplam sayısını vermektedir.