Zaktualizuj wygląd sklepu (storefront)
curl --request PUT \
--url https://api.itemshop.dev/api/v2/shops/{shopId}/storefront \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"description": "<string>",
"serverIp": "play.shop.pl",
"discordInviteUrl": "<string>",
"communitySize": 1,
"announcement": "<string>",
"languages": [
"<string>"
],
"translations": {},
"socials": {
"discord": "<string>",
"tiktok": "<string>",
"facebook": "<string>",
"youtube": "<string>",
"instagram": "<string>"
},
"monthlyGoal": {
"enabled": true,
"target": 1
},
"administration": [
{
"nickname": "Steve",
"role": "CEO"
}
],
"theme": {
"brandColor": "#ef592d",
"accentColor": "#facc15"
},
"hideCheckoutDiscount": true,
"hideCheckoutPaymentInfo": true,
"hideCheckoutSummary": true,
"hero": {
"title": "<string>",
"tagline": "<string>",
"renderNicks": [
"<string>"
],
"ctaLabel": "<string>",
"ctaHref": "<string>"
},
"sections": {
"showAnnouncement": true,
"showMonthlyGoal": true,
"showCatalog": true,
"showRecentPurchases": true,
"showTopSpenders": true,
"showAdministration": true
},
"publicData": {
"recentPurchases": true,
"topSpenders": true,
"monthlyGoal": true,
"onlinePlayers": true
},
"legal": {
"termsHtml": "<string>",
"privacyHtml": "<string>",
"companyInfo": "<string>"
},
"payments": {
"showStrip": true
},
"fontFamily": "<string>",
"navHideHome": true,
"logoUrl": "<string>",
"shopCtaLabel": "<string>",
"shopCtaHidden": true,
"chrome": {
"navbarTitle": "<string>",
"navShowOnline": true,
"navLinks": [
{
"label": "<string>",
"url": "<string>",
"newTab": true
}
],
"navHidden": true,
"footerHidden": true,
"navHeight": 200,
"navMaxWidth": 2000,
"footerPadY": 200,
"footerMaxWidth": 2000,
"footerDiscordTitle": "<string>",
"footerDiscordSubtitle": "<string>",
"footerHideDiscord": true,
"footerCopyright": "<string>",
"footerBrand": "<string>",
"footerLegalPl": "<string>",
"footerLegalEn": "<string>"
},
"layout": [
{
"id": "<string>",
"visible": true,
"props": {}
}
],
"pages": [
{
"id": "<string>",
"slug": "<string>",
"title": "<string>",
"nav": true,
"layout": [
{
"id": "<string>",
"visible": true,
"props": {}
}
]
}
]
}
'import requests
url = "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront"
payload = {
"description": "<string>",
"serverIp": "play.shop.pl",
"discordInviteUrl": "<string>",
"communitySize": 1,
"announcement": "<string>",
"languages": ["<string>"],
"translations": {},
"socials": {
"discord": "<string>",
"tiktok": "<string>",
"facebook": "<string>",
"youtube": "<string>",
"instagram": "<string>"
},
"monthlyGoal": {
"enabled": True,
"target": 1
},
"administration": [
{
"nickname": "Steve",
"role": "CEO"
}
],
"theme": {
"brandColor": "#ef592d",
"accentColor": "#facc15"
},
"hideCheckoutDiscount": True,
"hideCheckoutPaymentInfo": True,
"hideCheckoutSummary": True,
"hero": {
"title": "<string>",
"tagline": "<string>",
"renderNicks": ["<string>"],
"ctaLabel": "<string>",
"ctaHref": "<string>"
},
"sections": {
"showAnnouncement": True,
"showMonthlyGoal": True,
"showCatalog": True,
"showRecentPurchases": True,
"showTopSpenders": True,
"showAdministration": True
},
"publicData": {
"recentPurchases": True,
"topSpenders": True,
"monthlyGoal": True,
"onlinePlayers": True
},
"legal": {
"termsHtml": "<string>",
"privacyHtml": "<string>",
"companyInfo": "<string>"
},
"payments": { "showStrip": True },
"fontFamily": "<string>",
"navHideHome": True,
"logoUrl": "<string>",
"shopCtaLabel": "<string>",
"shopCtaHidden": True,
"chrome": {
"navbarTitle": "<string>",
"navShowOnline": True,
"navLinks": [
{
"label": "<string>",
"url": "<string>",
"newTab": True
}
],
"navHidden": True,
"footerHidden": True,
"navHeight": 200,
"navMaxWidth": 2000,
"footerPadY": 200,
"footerMaxWidth": 2000,
"footerDiscordTitle": "<string>",
"footerDiscordSubtitle": "<string>",
"footerHideDiscord": True,
"footerCopyright": "<string>",
"footerBrand": "<string>",
"footerLegalPl": "<string>",
"footerLegalEn": "<string>"
},
"layout": [
{
"id": "<string>",
"visible": True,
"props": {}
}
],
"pages": [
{
"id": "<string>",
"slug": "<string>",
"title": "<string>",
"nav": True,
"layout": [
{
"id": "<string>",
"visible": True,
"props": {}
}
]
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
description: '<string>',
serverIp: 'play.shop.pl',
discordInviteUrl: '<string>',
communitySize: 1,
announcement: '<string>',
languages: ['<string>'],
translations: {},
socials: {
discord: '<string>',
tiktok: '<string>',
facebook: '<string>',
youtube: '<string>',
instagram: '<string>'
},
monthlyGoal: {enabled: true, target: 1},
administration: [{nickname: 'Steve', role: 'CEO'}],
theme: {brandColor: '#ef592d', accentColor: '#facc15'},
hideCheckoutDiscount: true,
hideCheckoutPaymentInfo: true,
hideCheckoutSummary: true,
hero: {
title: '<string>',
tagline: '<string>',
renderNicks: ['<string>'],
ctaLabel: '<string>',
ctaHref: '<string>'
},
sections: {
showAnnouncement: true,
showMonthlyGoal: true,
showCatalog: true,
showRecentPurchases: true,
showTopSpenders: true,
showAdministration: true
},
publicData: {
recentPurchases: true,
topSpenders: true,
monthlyGoal: true,
onlinePlayers: true
},
legal: {termsHtml: '<string>', privacyHtml: '<string>', companyInfo: '<string>'},
payments: {showStrip: true},
fontFamily: '<string>',
navHideHome: true,
logoUrl: '<string>',
shopCtaLabel: '<string>',
shopCtaHidden: true,
chrome: {
navbarTitle: '<string>',
navShowOnline: true,
navLinks: [{label: '<string>', url: '<string>', newTab: true}],
navHidden: true,
footerHidden: true,
navHeight: 200,
navMaxWidth: 2000,
footerPadY: 200,
footerMaxWidth: 2000,
footerDiscordTitle: '<string>',
footerDiscordSubtitle: '<string>',
footerHideDiscord: true,
footerCopyright: '<string>',
footerBrand: '<string>',
footerLegalPl: '<string>',
footerLegalEn: '<string>'
},
layout: [{id: '<string>', visible: true, props: {}}],
pages: [
{
id: '<string>',
slug: '<string>',
title: '<string>',
nav: true,
layout: [{id: '<string>', visible: true, props: {}}]
}
]
})
};
fetch('https://api.itemshop.dev/api/v2/shops/{shopId}/storefront', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'description' => '<string>',
'serverIp' => 'play.shop.pl',
'discordInviteUrl' => '<string>',
'communitySize' => 1,
'announcement' => '<string>',
'languages' => [
'<string>'
],
'translations' => [
],
'socials' => [
'discord' => '<string>',
'tiktok' => '<string>',
'facebook' => '<string>',
'youtube' => '<string>',
'instagram' => '<string>'
],
'monthlyGoal' => [
'enabled' => true,
'target' => 1
],
'administration' => [
[
'nickname' => 'Steve',
'role' => 'CEO'
]
],
'theme' => [
'brandColor' => '#ef592d',
'accentColor' => '#facc15'
],
'hideCheckoutDiscount' => true,
'hideCheckoutPaymentInfo' => true,
'hideCheckoutSummary' => true,
'hero' => [
'title' => '<string>',
'tagline' => '<string>',
'renderNicks' => [
'<string>'
],
'ctaLabel' => '<string>',
'ctaHref' => '<string>'
],
'sections' => [
'showAnnouncement' => true,
'showMonthlyGoal' => true,
'showCatalog' => true,
'showRecentPurchases' => true,
'showTopSpenders' => true,
'showAdministration' => true
],
'publicData' => [
'recentPurchases' => true,
'topSpenders' => true,
'monthlyGoal' => true,
'onlinePlayers' => true
],
'legal' => [
'termsHtml' => '<string>',
'privacyHtml' => '<string>',
'companyInfo' => '<string>'
],
'payments' => [
'showStrip' => true
],
'fontFamily' => '<string>',
'navHideHome' => true,
'logoUrl' => '<string>',
'shopCtaLabel' => '<string>',
'shopCtaHidden' => true,
'chrome' => [
'navbarTitle' => '<string>',
'navShowOnline' => true,
'navLinks' => [
[
'label' => '<string>',
'url' => '<string>',
'newTab' => true
]
],
'navHidden' => true,
'footerHidden' => true,
'navHeight' => 200,
'navMaxWidth' => 2000,
'footerPadY' => 200,
'footerMaxWidth' => 2000,
'footerDiscordTitle' => '<string>',
'footerDiscordSubtitle' => '<string>',
'footerHideDiscord' => true,
'footerCopyright' => '<string>',
'footerBrand' => '<string>',
'footerLegalPl' => '<string>',
'footerLegalEn' => '<string>'
],
'layout' => [
[
'id' => '<string>',
'visible' => true,
'props' => [
]
]
],
'pages' => [
[
'id' => '<string>',
'slug' => '<string>',
'title' => '<string>',
'nav' => true,
'layout' => [
[
'id' => '<string>',
'visible' => true,
'props' => [
]
]
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront"
payload := strings.NewReader("{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.itemshop.dev/api/v2/shops/{shopId}/storefront")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.itemshop.dev/api/v2/shops/{shopId}/storefront")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"_id": "664f1a2b3c4d5e6f7a8b9c0d",
"uniqueName": "moj-sklep",
"displayName": "Mój Sklep",
"frontEndUrl": "https://moj-sklep.pl",
"isActive": true,
"createdAt": "2023-11-07T05:31:56Z"
},
"message": "<string>"
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}Autoryzacje
Parametry ścieżki
ID sklepu (ObjectId)
Treść
Opis w hero
500IP serwera
120"play.shop.pl"
Zaproszenie Discord
300Wielkość społeczności
x >= 0Baner ogłoszenia
500Włączone języki (ISO)
20Tłumaczenia storefrontu per język
Show child attributes
Show child attributes
Show child attributes
Show child attributes
50Show child attributes
Show child attributes
Show child attributes
Show child attributes
Checkout page layout
split, inline, modal Hide the discount-code field in checkout
Hide the payment-operator legal strip in checkout
Hide the order-summary block in the 2-step modal checkout
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Czcionka storefrontu
60Ukryj „Strona główna" w nawigacji
URL logo w navbarze
500^(https?:\/\/|\/|$)Etykieta przycisku „Sklep"
40Ukryj przycisk „Sklep"
Nadpisania navbar/stopki
Show child attributes
Show child attributes
Układ bloków strony
50Show child attributes
Show child attributes
Podstrony edytora
30Show child attributes
Show child attributes
Czy ta strona była pomocna?
curl --request PUT \
--url https://api.itemshop.dev/api/v2/shops/{shopId}/storefront \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"description": "<string>",
"serverIp": "play.shop.pl",
"discordInviteUrl": "<string>",
"communitySize": 1,
"announcement": "<string>",
"languages": [
"<string>"
],
"translations": {},
"socials": {
"discord": "<string>",
"tiktok": "<string>",
"facebook": "<string>",
"youtube": "<string>",
"instagram": "<string>"
},
"monthlyGoal": {
"enabled": true,
"target": 1
},
"administration": [
{
"nickname": "Steve",
"role": "CEO"
}
],
"theme": {
"brandColor": "#ef592d",
"accentColor": "#facc15"
},
"hideCheckoutDiscount": true,
"hideCheckoutPaymentInfo": true,
"hideCheckoutSummary": true,
"hero": {
"title": "<string>",
"tagline": "<string>",
"renderNicks": [
"<string>"
],
"ctaLabel": "<string>",
"ctaHref": "<string>"
},
"sections": {
"showAnnouncement": true,
"showMonthlyGoal": true,
"showCatalog": true,
"showRecentPurchases": true,
"showTopSpenders": true,
"showAdministration": true
},
"publicData": {
"recentPurchases": true,
"topSpenders": true,
"monthlyGoal": true,
"onlinePlayers": true
},
"legal": {
"termsHtml": "<string>",
"privacyHtml": "<string>",
"companyInfo": "<string>"
},
"payments": {
"showStrip": true
},
"fontFamily": "<string>",
"navHideHome": true,
"logoUrl": "<string>",
"shopCtaLabel": "<string>",
"shopCtaHidden": true,
"chrome": {
"navbarTitle": "<string>",
"navShowOnline": true,
"navLinks": [
{
"label": "<string>",
"url": "<string>",
"newTab": true
}
],
"navHidden": true,
"footerHidden": true,
"navHeight": 200,
"navMaxWidth": 2000,
"footerPadY": 200,
"footerMaxWidth": 2000,
"footerDiscordTitle": "<string>",
"footerDiscordSubtitle": "<string>",
"footerHideDiscord": true,
"footerCopyright": "<string>",
"footerBrand": "<string>",
"footerLegalPl": "<string>",
"footerLegalEn": "<string>"
},
"layout": [
{
"id": "<string>",
"visible": true,
"props": {}
}
],
"pages": [
{
"id": "<string>",
"slug": "<string>",
"title": "<string>",
"nav": true,
"layout": [
{
"id": "<string>",
"visible": true,
"props": {}
}
]
}
]
}
'import requests
url = "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront"
payload = {
"description": "<string>",
"serverIp": "play.shop.pl",
"discordInviteUrl": "<string>",
"communitySize": 1,
"announcement": "<string>",
"languages": ["<string>"],
"translations": {},
"socials": {
"discord": "<string>",
"tiktok": "<string>",
"facebook": "<string>",
"youtube": "<string>",
"instagram": "<string>"
},
"monthlyGoal": {
"enabled": True,
"target": 1
},
"administration": [
{
"nickname": "Steve",
"role": "CEO"
}
],
"theme": {
"brandColor": "#ef592d",
"accentColor": "#facc15"
},
"hideCheckoutDiscount": True,
"hideCheckoutPaymentInfo": True,
"hideCheckoutSummary": True,
"hero": {
"title": "<string>",
"tagline": "<string>",
"renderNicks": ["<string>"],
"ctaLabel": "<string>",
"ctaHref": "<string>"
},
"sections": {
"showAnnouncement": True,
"showMonthlyGoal": True,
"showCatalog": True,
"showRecentPurchases": True,
"showTopSpenders": True,
"showAdministration": True
},
"publicData": {
"recentPurchases": True,
"topSpenders": True,
"monthlyGoal": True,
"onlinePlayers": True
},
"legal": {
"termsHtml": "<string>",
"privacyHtml": "<string>",
"companyInfo": "<string>"
},
"payments": { "showStrip": True },
"fontFamily": "<string>",
"navHideHome": True,
"logoUrl": "<string>",
"shopCtaLabel": "<string>",
"shopCtaHidden": True,
"chrome": {
"navbarTitle": "<string>",
"navShowOnline": True,
"navLinks": [
{
"label": "<string>",
"url": "<string>",
"newTab": True
}
],
"navHidden": True,
"footerHidden": True,
"navHeight": 200,
"navMaxWidth": 2000,
"footerPadY": 200,
"footerMaxWidth": 2000,
"footerDiscordTitle": "<string>",
"footerDiscordSubtitle": "<string>",
"footerHideDiscord": True,
"footerCopyright": "<string>",
"footerBrand": "<string>",
"footerLegalPl": "<string>",
"footerLegalEn": "<string>"
},
"layout": [
{
"id": "<string>",
"visible": True,
"props": {}
}
],
"pages": [
{
"id": "<string>",
"slug": "<string>",
"title": "<string>",
"nav": True,
"layout": [
{
"id": "<string>",
"visible": True,
"props": {}
}
]
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
description: '<string>',
serverIp: 'play.shop.pl',
discordInviteUrl: '<string>',
communitySize: 1,
announcement: '<string>',
languages: ['<string>'],
translations: {},
socials: {
discord: '<string>',
tiktok: '<string>',
facebook: '<string>',
youtube: '<string>',
instagram: '<string>'
},
monthlyGoal: {enabled: true, target: 1},
administration: [{nickname: 'Steve', role: 'CEO'}],
theme: {brandColor: '#ef592d', accentColor: '#facc15'},
hideCheckoutDiscount: true,
hideCheckoutPaymentInfo: true,
hideCheckoutSummary: true,
hero: {
title: '<string>',
tagline: '<string>',
renderNicks: ['<string>'],
ctaLabel: '<string>',
ctaHref: '<string>'
},
sections: {
showAnnouncement: true,
showMonthlyGoal: true,
showCatalog: true,
showRecentPurchases: true,
showTopSpenders: true,
showAdministration: true
},
publicData: {
recentPurchases: true,
topSpenders: true,
monthlyGoal: true,
onlinePlayers: true
},
legal: {termsHtml: '<string>', privacyHtml: '<string>', companyInfo: '<string>'},
payments: {showStrip: true},
fontFamily: '<string>',
navHideHome: true,
logoUrl: '<string>',
shopCtaLabel: '<string>',
shopCtaHidden: true,
chrome: {
navbarTitle: '<string>',
navShowOnline: true,
navLinks: [{label: '<string>', url: '<string>', newTab: true}],
navHidden: true,
footerHidden: true,
navHeight: 200,
navMaxWidth: 2000,
footerPadY: 200,
footerMaxWidth: 2000,
footerDiscordTitle: '<string>',
footerDiscordSubtitle: '<string>',
footerHideDiscord: true,
footerCopyright: '<string>',
footerBrand: '<string>',
footerLegalPl: '<string>',
footerLegalEn: '<string>'
},
layout: [{id: '<string>', visible: true, props: {}}],
pages: [
{
id: '<string>',
slug: '<string>',
title: '<string>',
nav: true,
layout: [{id: '<string>', visible: true, props: {}}]
}
]
})
};
fetch('https://api.itemshop.dev/api/v2/shops/{shopId}/storefront', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'description' => '<string>',
'serverIp' => 'play.shop.pl',
'discordInviteUrl' => '<string>',
'communitySize' => 1,
'announcement' => '<string>',
'languages' => [
'<string>'
],
'translations' => [
],
'socials' => [
'discord' => '<string>',
'tiktok' => '<string>',
'facebook' => '<string>',
'youtube' => '<string>',
'instagram' => '<string>'
],
'monthlyGoal' => [
'enabled' => true,
'target' => 1
],
'administration' => [
[
'nickname' => 'Steve',
'role' => 'CEO'
]
],
'theme' => [
'brandColor' => '#ef592d',
'accentColor' => '#facc15'
],
'hideCheckoutDiscount' => true,
'hideCheckoutPaymentInfo' => true,
'hideCheckoutSummary' => true,
'hero' => [
'title' => '<string>',
'tagline' => '<string>',
'renderNicks' => [
'<string>'
],
'ctaLabel' => '<string>',
'ctaHref' => '<string>'
],
'sections' => [
'showAnnouncement' => true,
'showMonthlyGoal' => true,
'showCatalog' => true,
'showRecentPurchases' => true,
'showTopSpenders' => true,
'showAdministration' => true
],
'publicData' => [
'recentPurchases' => true,
'topSpenders' => true,
'monthlyGoal' => true,
'onlinePlayers' => true
],
'legal' => [
'termsHtml' => '<string>',
'privacyHtml' => '<string>',
'companyInfo' => '<string>'
],
'payments' => [
'showStrip' => true
],
'fontFamily' => '<string>',
'navHideHome' => true,
'logoUrl' => '<string>',
'shopCtaLabel' => '<string>',
'shopCtaHidden' => true,
'chrome' => [
'navbarTitle' => '<string>',
'navShowOnline' => true,
'navLinks' => [
[
'label' => '<string>',
'url' => '<string>',
'newTab' => true
]
],
'navHidden' => true,
'footerHidden' => true,
'navHeight' => 200,
'navMaxWidth' => 2000,
'footerPadY' => 200,
'footerMaxWidth' => 2000,
'footerDiscordTitle' => '<string>',
'footerDiscordSubtitle' => '<string>',
'footerHideDiscord' => true,
'footerCopyright' => '<string>',
'footerBrand' => '<string>',
'footerLegalPl' => '<string>',
'footerLegalEn' => '<string>'
],
'layout' => [
[
'id' => '<string>',
'visible' => true,
'props' => [
]
]
],
'pages' => [
[
'id' => '<string>',
'slug' => '<string>',
'title' => '<string>',
'nav' => true,
'layout' => [
[
'id' => '<string>',
'visible' => true,
'props' => [
]
]
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.itemshop.dev/api/v2/shops/{shopId}/storefront"
payload := strings.NewReader("{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.itemshop.dev/api/v2/shops/{shopId}/storefront")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.itemshop.dev/api/v2/shops/{shopId}/storefront")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"description\": \"<string>\",\n \"serverIp\": \"play.shop.pl\",\n \"discordInviteUrl\": \"<string>\",\n \"communitySize\": 1,\n \"announcement\": \"<string>\",\n \"languages\": [\n \"<string>\"\n ],\n \"translations\": {},\n \"socials\": {\n \"discord\": \"<string>\",\n \"tiktok\": \"<string>\",\n \"facebook\": \"<string>\",\n \"youtube\": \"<string>\",\n \"instagram\": \"<string>\"\n },\n \"monthlyGoal\": {\n \"enabled\": true,\n \"target\": 1\n },\n \"administration\": [\n {\n \"nickname\": \"Steve\",\n \"role\": \"CEO\"\n }\n ],\n \"theme\": {\n \"brandColor\": \"#ef592d\",\n \"accentColor\": \"#facc15\"\n },\n \"hideCheckoutDiscount\": true,\n \"hideCheckoutPaymentInfo\": true,\n \"hideCheckoutSummary\": true,\n \"hero\": {\n \"title\": \"<string>\",\n \"tagline\": \"<string>\",\n \"renderNicks\": [\n \"<string>\"\n ],\n \"ctaLabel\": \"<string>\",\n \"ctaHref\": \"<string>\"\n },\n \"sections\": {\n \"showAnnouncement\": true,\n \"showMonthlyGoal\": true,\n \"showCatalog\": true,\n \"showRecentPurchases\": true,\n \"showTopSpenders\": true,\n \"showAdministration\": true\n },\n \"publicData\": {\n \"recentPurchases\": true,\n \"topSpenders\": true,\n \"monthlyGoal\": true,\n \"onlinePlayers\": true\n },\n \"legal\": {\n \"termsHtml\": \"<string>\",\n \"privacyHtml\": \"<string>\",\n \"companyInfo\": \"<string>\"\n },\n \"payments\": {\n \"showStrip\": true\n },\n \"fontFamily\": \"<string>\",\n \"navHideHome\": true,\n \"logoUrl\": \"<string>\",\n \"shopCtaLabel\": \"<string>\",\n \"shopCtaHidden\": true,\n \"chrome\": {\n \"navbarTitle\": \"<string>\",\n \"navShowOnline\": true,\n \"navLinks\": [\n {\n \"label\": \"<string>\",\n \"url\": \"<string>\",\n \"newTab\": true\n }\n ],\n \"navHidden\": true,\n \"footerHidden\": true,\n \"navHeight\": 200,\n \"navMaxWidth\": 2000,\n \"footerPadY\": 200,\n \"footerMaxWidth\": 2000,\n \"footerDiscordTitle\": \"<string>\",\n \"footerDiscordSubtitle\": \"<string>\",\n \"footerHideDiscord\": true,\n \"footerCopyright\": \"<string>\",\n \"footerBrand\": \"<string>\",\n \"footerLegalPl\": \"<string>\",\n \"footerLegalEn\": \"<string>\"\n },\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ],\n \"pages\": [\n {\n \"id\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"nav\": true,\n \"layout\": [\n {\n \"id\": \"<string>\",\n \"visible\": true,\n \"props\": {}\n }\n ]\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"_id": "664f1a2b3c4d5e6f7a8b9c0d",
"uniqueName": "moj-sklep",
"displayName": "Mój Sklep",
"frontEndUrl": "https://moj-sklep.pl",
"isActive": true,
"createdAt": "2023-11-07T05:31:56Z"
},
"message": "<string>"
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}{
"success": false,
"statusCode": 400,
"error": "Komunikat błędu",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/api/v2/..."
}