Aktualizuj pozycję cennika
curl --request PATCH \
--url https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId} \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"price": 200,
"details": "{\"currency\":\"PLN\",\"vat\":23}"
}
'import requests
url = "https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}"
payload = {
"price": 200,
"details": "{\"currency\":\"PLN\",\"vat\":23}"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({price: 200, details: '{"currency":"PLN","vat":23}'})
};
fetch('https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}', 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://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'price' => 200,
'details' => '{"currency":"PLN","vat":23}'
]),
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://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}"
payload := strings.NewReader("{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}"
response = http.request(request)
puts response.read_bodyCennik
Aktualizuj pozycję cennika
Aktualizuje pozycję cenową. Zmiana jest natychmiast widoczna dla klientów wybierających daną opcję.
PATCH
/
api
/
pay
/
products
/
{productId}
/
pricing
/
entries
/
{entryId}
Aktualizuj pozycję cennika
curl --request PATCH \
--url https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId} \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"price": 200,
"details": "{\"currency\":\"PLN\",\"vat\":23}"
}
'import requests
url = "https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}"
payload = {
"price": 200,
"details": "{\"currency\":\"PLN\",\"vat\":23}"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({price: 200, details: '{"currency":"PLN","vat":23}'})
};
fetch('https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}', 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://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'price' => 200,
'details' => '{"currency":"PLN","vat":23}'
]),
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://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}"
payload := strings.NewReader("{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gateway-api.sandbox.paymove.io/api/pay/products/{productId}/pricing/entries/{entryId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"price\": 200,\n \"details\": \"{\\\"currency\\\":\\\"PLN\\\",\\\"vat\\\":23}\"\n}"
response = http.request(request)
puts response.read_bodyAutoryzacje
Klucz API dostarczony przez Paymove po zakończeniu procesu KYC.
Przykład: sk_test_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Parametry ścieżki
Identyfikator produktu (id z odpowiedzi przy tworzeniu produktu)
Przykład:
"d0a834f9-94a4-4b3a-aa10-27d911e3633f"
Identyfikator pozycji cennika
Treść
application/json
Odpowiedź
200
Pozycja cennika zaktualizowana
⌘I