curl --request PUT \
--url https://sandbox.api.veepag.com/v1/product \
--header 'Content-Type: application/json' \
--header 'apiKey: <api-key>' \
--data '
{
"companyId": "<string>",
"active": true,
"deleted": true,
"setting": {
"re1to1": true,
"successChargeDay": true,
"cardAuth": true,
"limitOverdueCharges": {
"active": true,
"qty": 123
}
},
"charge": {
"frequencyDays": 1,
"deniedIntervalDays": 1,
"maxDeniedAttempts": 1,
"invoiceIdentification": "<string>",
"paymentMethod": [
{
"active": true,
"installments": [
{
"installment": 123,
"fee": 1,
"totalAmount": 1,
"installmentAmount": 1
}
]
}
],
"routes": []
},
"product": {
"price": 1,
"originalPrice": 1,
"title": "<string>",
"photo": "<string>",
"warranty": 1,
"description": "<string>",
"SKU": "<string>"
},
"unsubscription": {
"overdueDays": 1
},
"checkout": {
"header": {
"color": "<string>",
"fixed": true,
"active": true,
"logo": "<string>"
},
"topBanner": {
"active": true,
"url": "<string>"
},
"sideBanner": {
"active": true,
"url": "<string>"
},
"contact": {
"active": true,
"text": "<string>"
},
"terms": {
"active": true,
"text": "<string>"
},
"privacyterms": {
"active": true,
"linkTermsUse": "<string>",
"linkPrivacyPolicy": "<string>"
},
"tracking": {
"meta": "<string>",
"gtm": "<string>"
},
"color": {
"textPrimary": "<string>",
"secondary": "<string>",
"background": "<string>",
"primary": "<string>",
"textSecondary": "<string>"
},
"countdown": {
"time": 123,
"fixed": true,
"active": true,
"color": {
"background": "<string>",
"text": "<string>"
}
},
"faq": {
"active": true,
"list": [
{
"question": "<string>",
"answer": "<string>"
}
]
}
},
"send": {
"active": true,
"list": [
{
"active": true,
"id": "<string>",
"integrationId": "<string>",
"linkAccess": "<string>",
"name": "<string>",
"productId": "<string>"
}
]
},
"discount": {
"list": []
},
"notification": {
"overdueCharge": {
"email": true
},
"paidCharge": {
"email": true,
"message": "<string>"
}
},
"_id": "<string>"
}
'import requests
url = "https://sandbox.api.veepag.com/v1/product"
payload = {
"companyId": "<string>",
"active": True,
"deleted": True,
"setting": {
"re1to1": True,
"successChargeDay": True,
"cardAuth": True,
"limitOverdueCharges": {
"active": True,
"qty": 123
}
},
"charge": {
"frequencyDays": 1,
"deniedIntervalDays": 1,
"maxDeniedAttempts": 1,
"invoiceIdentification": "<string>",
"paymentMethod": [
{
"active": True,
"installments": [
{
"installment": 123,
"fee": 1,
"totalAmount": 1,
"installmentAmount": 1
}
]
}
],
"routes": []
},
"product": {
"price": 1,
"originalPrice": 1,
"title": "<string>",
"photo": "<string>",
"warranty": 1,
"description": "<string>",
"SKU": "<string>"
},
"unsubscription": { "overdueDays": 1 },
"checkout": {
"header": {
"color": "<string>",
"fixed": True,
"active": True,
"logo": "<string>"
},
"topBanner": {
"active": True,
"url": "<string>"
},
"sideBanner": {
"active": True,
"url": "<string>"
},
"contact": {
"active": True,
"text": "<string>"
},
"terms": {
"active": True,
"text": "<string>"
},
"privacyterms": {
"active": True,
"linkTermsUse": "<string>",
"linkPrivacyPolicy": "<string>"
},
"tracking": {
"meta": "<string>",
"gtm": "<string>"
},
"color": {
"textPrimary": "<string>",
"secondary": "<string>",
"background": "<string>",
"primary": "<string>",
"textSecondary": "<string>"
},
"countdown": {
"time": 123,
"fixed": True,
"active": True,
"color": {
"background": "<string>",
"text": "<string>"
}
},
"faq": {
"active": True,
"list": [
{
"question": "<string>",
"answer": "<string>"
}
]
}
},
"send": {
"active": True,
"list": [
{
"active": True,
"id": "<string>",
"integrationId": "<string>",
"linkAccess": "<string>",
"name": "<string>",
"productId": "<string>"
}
]
},
"discount": { "list": [] },
"notification": {
"overdueCharge": { "email": True },
"paidCharge": {
"email": True,
"message": "<string>"
}
},
"_id": "<string>"
}
headers = {
"apiKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {apiKey: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
companyId: '<string>',
active: true,
deleted: true,
setting: {
re1to1: true,
successChargeDay: true,
cardAuth: true,
limitOverdueCharges: {active: true, qty: 123}
},
charge: {
frequencyDays: 1,
deniedIntervalDays: 1,
maxDeniedAttempts: 1,
invoiceIdentification: '<string>',
paymentMethod: [
{
active: true,
installments: [{installment: 123, fee: 1, totalAmount: 1, installmentAmount: 1}]
}
],
routes: []
},
product: {
price: 1,
originalPrice: 1,
title: '<string>',
photo: '<string>',
warranty: 1,
description: '<string>',
SKU: '<string>'
},
unsubscription: {overdueDays: 1},
checkout: {
header: {color: '<string>', fixed: true, active: true, logo: '<string>'},
topBanner: {active: true, url: '<string>'},
sideBanner: {active: true, url: '<string>'},
contact: {active: true, text: '<string>'},
terms: {active: true, text: '<string>'},
privacyterms: {active: true, linkTermsUse: '<string>', linkPrivacyPolicy: '<string>'},
tracking: {meta: '<string>', gtm: '<string>'},
color: {
textPrimary: '<string>',
secondary: '<string>',
background: '<string>',
primary: '<string>',
textSecondary: '<string>'
},
countdown: {
time: 123,
fixed: true,
active: true,
color: {background: '<string>', text: '<string>'}
},
faq: {active: true, list: [{question: '<string>', answer: '<string>'}]}
},
send: {
active: true,
list: [
{
active: true,
id: '<string>',
integrationId: '<string>',
linkAccess: '<string>',
name: '<string>',
productId: '<string>'
}
]
},
discount: {list: []},
notification: {overdueCharge: {email: true}, paidCharge: {email: true, message: '<string>'}},
_id: '<string>'
})
};
fetch('https://sandbox.api.veepag.com/v1/product', 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://sandbox.api.veepag.com/v1/product",
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([
'companyId' => '<string>',
'active' => true,
'deleted' => true,
'setting' => [
're1to1' => true,
'successChargeDay' => true,
'cardAuth' => true,
'limitOverdueCharges' => [
'active' => true,
'qty' => 123
]
],
'charge' => [
'frequencyDays' => 1,
'deniedIntervalDays' => 1,
'maxDeniedAttempts' => 1,
'invoiceIdentification' => '<string>',
'paymentMethod' => [
[
'active' => true,
'installments' => [
[
'installment' => 123,
'fee' => 1,
'totalAmount' => 1,
'installmentAmount' => 1
]
]
]
],
'routes' => [
]
],
'product' => [
'price' => 1,
'originalPrice' => 1,
'title' => '<string>',
'photo' => '<string>',
'warranty' => 1,
'description' => '<string>',
'SKU' => '<string>'
],
'unsubscription' => [
'overdueDays' => 1
],
'checkout' => [
'header' => [
'color' => '<string>',
'fixed' => true,
'active' => true,
'logo' => '<string>'
],
'topBanner' => [
'active' => true,
'url' => '<string>'
],
'sideBanner' => [
'active' => true,
'url' => '<string>'
],
'contact' => [
'active' => true,
'text' => '<string>'
],
'terms' => [
'active' => true,
'text' => '<string>'
],
'privacyterms' => [
'active' => true,
'linkTermsUse' => '<string>',
'linkPrivacyPolicy' => '<string>'
],
'tracking' => [
'meta' => '<string>',
'gtm' => '<string>'
],
'color' => [
'textPrimary' => '<string>',
'secondary' => '<string>',
'background' => '<string>',
'primary' => '<string>',
'textSecondary' => '<string>'
],
'countdown' => [
'time' => 123,
'fixed' => true,
'active' => true,
'color' => [
'background' => '<string>',
'text' => '<string>'
]
],
'faq' => [
'active' => true,
'list' => [
[
'question' => '<string>',
'answer' => '<string>'
]
]
]
],
'send' => [
'active' => true,
'list' => [
[
'active' => true,
'id' => '<string>',
'integrationId' => '<string>',
'linkAccess' => '<string>',
'name' => '<string>',
'productId' => '<string>'
]
]
],
'discount' => [
'list' => [
]
],
'notification' => [
'overdueCharge' => [
'email' => true
],
'paidCharge' => [
'email' => true,
'message' => '<string>'
]
],
'_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"apiKey: <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://sandbox.api.veepag.com/v1/product"
payload := strings.NewReader("{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("apiKey", "<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://sandbox.api.veepag.com/v1/product")
.header("apiKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.api.veepag.com/v1/product")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["apiKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"_id": "product_id",
"active": true
}{
"error_messages": [
{
"msg": "Payload invalido.",
"type": "field",
"path": "companyId",
"location": "body"
}
],
"code": "ZodValidationException",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Unauthorized."
}
],
"code": "unauthorized",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Forbidden."
}
],
"code": "forbidden",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Unknown server error."
}
],
"code": "unknown_server_error",
"path": "/v1/product",
"metadata": {}
}Update a product
Atualiza parcialmente um produto. Campos invalidos podem ser descartados no preprocessamento.
curl --request PUT \
--url https://sandbox.api.veepag.com/v1/product \
--header 'Content-Type: application/json' \
--header 'apiKey: <api-key>' \
--data '
{
"companyId": "<string>",
"active": true,
"deleted": true,
"setting": {
"re1to1": true,
"successChargeDay": true,
"cardAuth": true,
"limitOverdueCharges": {
"active": true,
"qty": 123
}
},
"charge": {
"frequencyDays": 1,
"deniedIntervalDays": 1,
"maxDeniedAttempts": 1,
"invoiceIdentification": "<string>",
"paymentMethod": [
{
"active": true,
"installments": [
{
"installment": 123,
"fee": 1,
"totalAmount": 1,
"installmentAmount": 1
}
]
}
],
"routes": []
},
"product": {
"price": 1,
"originalPrice": 1,
"title": "<string>",
"photo": "<string>",
"warranty": 1,
"description": "<string>",
"SKU": "<string>"
},
"unsubscription": {
"overdueDays": 1
},
"checkout": {
"header": {
"color": "<string>",
"fixed": true,
"active": true,
"logo": "<string>"
},
"topBanner": {
"active": true,
"url": "<string>"
},
"sideBanner": {
"active": true,
"url": "<string>"
},
"contact": {
"active": true,
"text": "<string>"
},
"terms": {
"active": true,
"text": "<string>"
},
"privacyterms": {
"active": true,
"linkTermsUse": "<string>",
"linkPrivacyPolicy": "<string>"
},
"tracking": {
"meta": "<string>",
"gtm": "<string>"
},
"color": {
"textPrimary": "<string>",
"secondary": "<string>",
"background": "<string>",
"primary": "<string>",
"textSecondary": "<string>"
},
"countdown": {
"time": 123,
"fixed": true,
"active": true,
"color": {
"background": "<string>",
"text": "<string>"
}
},
"faq": {
"active": true,
"list": [
{
"question": "<string>",
"answer": "<string>"
}
]
}
},
"send": {
"active": true,
"list": [
{
"active": true,
"id": "<string>",
"integrationId": "<string>",
"linkAccess": "<string>",
"name": "<string>",
"productId": "<string>"
}
]
},
"discount": {
"list": []
},
"notification": {
"overdueCharge": {
"email": true
},
"paidCharge": {
"email": true,
"message": "<string>"
}
},
"_id": "<string>"
}
'import requests
url = "https://sandbox.api.veepag.com/v1/product"
payload = {
"companyId": "<string>",
"active": True,
"deleted": True,
"setting": {
"re1to1": True,
"successChargeDay": True,
"cardAuth": True,
"limitOverdueCharges": {
"active": True,
"qty": 123
}
},
"charge": {
"frequencyDays": 1,
"deniedIntervalDays": 1,
"maxDeniedAttempts": 1,
"invoiceIdentification": "<string>",
"paymentMethod": [
{
"active": True,
"installments": [
{
"installment": 123,
"fee": 1,
"totalAmount": 1,
"installmentAmount": 1
}
]
}
],
"routes": []
},
"product": {
"price": 1,
"originalPrice": 1,
"title": "<string>",
"photo": "<string>",
"warranty": 1,
"description": "<string>",
"SKU": "<string>"
},
"unsubscription": { "overdueDays": 1 },
"checkout": {
"header": {
"color": "<string>",
"fixed": True,
"active": True,
"logo": "<string>"
},
"topBanner": {
"active": True,
"url": "<string>"
},
"sideBanner": {
"active": True,
"url": "<string>"
},
"contact": {
"active": True,
"text": "<string>"
},
"terms": {
"active": True,
"text": "<string>"
},
"privacyterms": {
"active": True,
"linkTermsUse": "<string>",
"linkPrivacyPolicy": "<string>"
},
"tracking": {
"meta": "<string>",
"gtm": "<string>"
},
"color": {
"textPrimary": "<string>",
"secondary": "<string>",
"background": "<string>",
"primary": "<string>",
"textSecondary": "<string>"
},
"countdown": {
"time": 123,
"fixed": True,
"active": True,
"color": {
"background": "<string>",
"text": "<string>"
}
},
"faq": {
"active": True,
"list": [
{
"question": "<string>",
"answer": "<string>"
}
]
}
},
"send": {
"active": True,
"list": [
{
"active": True,
"id": "<string>",
"integrationId": "<string>",
"linkAccess": "<string>",
"name": "<string>",
"productId": "<string>"
}
]
},
"discount": { "list": [] },
"notification": {
"overdueCharge": { "email": True },
"paidCharge": {
"email": True,
"message": "<string>"
}
},
"_id": "<string>"
}
headers = {
"apiKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {apiKey: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
companyId: '<string>',
active: true,
deleted: true,
setting: {
re1to1: true,
successChargeDay: true,
cardAuth: true,
limitOverdueCharges: {active: true, qty: 123}
},
charge: {
frequencyDays: 1,
deniedIntervalDays: 1,
maxDeniedAttempts: 1,
invoiceIdentification: '<string>',
paymentMethod: [
{
active: true,
installments: [{installment: 123, fee: 1, totalAmount: 1, installmentAmount: 1}]
}
],
routes: []
},
product: {
price: 1,
originalPrice: 1,
title: '<string>',
photo: '<string>',
warranty: 1,
description: '<string>',
SKU: '<string>'
},
unsubscription: {overdueDays: 1},
checkout: {
header: {color: '<string>', fixed: true, active: true, logo: '<string>'},
topBanner: {active: true, url: '<string>'},
sideBanner: {active: true, url: '<string>'},
contact: {active: true, text: '<string>'},
terms: {active: true, text: '<string>'},
privacyterms: {active: true, linkTermsUse: '<string>', linkPrivacyPolicy: '<string>'},
tracking: {meta: '<string>', gtm: '<string>'},
color: {
textPrimary: '<string>',
secondary: '<string>',
background: '<string>',
primary: '<string>',
textSecondary: '<string>'
},
countdown: {
time: 123,
fixed: true,
active: true,
color: {background: '<string>', text: '<string>'}
},
faq: {active: true, list: [{question: '<string>', answer: '<string>'}]}
},
send: {
active: true,
list: [
{
active: true,
id: '<string>',
integrationId: '<string>',
linkAccess: '<string>',
name: '<string>',
productId: '<string>'
}
]
},
discount: {list: []},
notification: {overdueCharge: {email: true}, paidCharge: {email: true, message: '<string>'}},
_id: '<string>'
})
};
fetch('https://sandbox.api.veepag.com/v1/product', 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://sandbox.api.veepag.com/v1/product",
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([
'companyId' => '<string>',
'active' => true,
'deleted' => true,
'setting' => [
're1to1' => true,
'successChargeDay' => true,
'cardAuth' => true,
'limitOverdueCharges' => [
'active' => true,
'qty' => 123
]
],
'charge' => [
'frequencyDays' => 1,
'deniedIntervalDays' => 1,
'maxDeniedAttempts' => 1,
'invoiceIdentification' => '<string>',
'paymentMethod' => [
[
'active' => true,
'installments' => [
[
'installment' => 123,
'fee' => 1,
'totalAmount' => 1,
'installmentAmount' => 1
]
]
]
],
'routes' => [
]
],
'product' => [
'price' => 1,
'originalPrice' => 1,
'title' => '<string>',
'photo' => '<string>',
'warranty' => 1,
'description' => '<string>',
'SKU' => '<string>'
],
'unsubscription' => [
'overdueDays' => 1
],
'checkout' => [
'header' => [
'color' => '<string>',
'fixed' => true,
'active' => true,
'logo' => '<string>'
],
'topBanner' => [
'active' => true,
'url' => '<string>'
],
'sideBanner' => [
'active' => true,
'url' => '<string>'
],
'contact' => [
'active' => true,
'text' => '<string>'
],
'terms' => [
'active' => true,
'text' => '<string>'
],
'privacyterms' => [
'active' => true,
'linkTermsUse' => '<string>',
'linkPrivacyPolicy' => '<string>'
],
'tracking' => [
'meta' => '<string>',
'gtm' => '<string>'
],
'color' => [
'textPrimary' => '<string>',
'secondary' => '<string>',
'background' => '<string>',
'primary' => '<string>',
'textSecondary' => '<string>'
],
'countdown' => [
'time' => 123,
'fixed' => true,
'active' => true,
'color' => [
'background' => '<string>',
'text' => '<string>'
]
],
'faq' => [
'active' => true,
'list' => [
[
'question' => '<string>',
'answer' => '<string>'
]
]
]
],
'send' => [
'active' => true,
'list' => [
[
'active' => true,
'id' => '<string>',
'integrationId' => '<string>',
'linkAccess' => '<string>',
'name' => '<string>',
'productId' => '<string>'
]
]
],
'discount' => [
'list' => [
]
],
'notification' => [
'overdueCharge' => [
'email' => true
],
'paidCharge' => [
'email' => true,
'message' => '<string>'
]
],
'_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"apiKey: <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://sandbox.api.veepag.com/v1/product"
payload := strings.NewReader("{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("apiKey", "<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://sandbox.api.veepag.com/v1/product")
.header("apiKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.api.veepag.com/v1/product")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["apiKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"companyId\": \"<string>\",\n \"active\": true,\n \"deleted\": true,\n \"setting\": {\n \"re1to1\": true,\n \"successChargeDay\": true,\n \"cardAuth\": true,\n \"limitOverdueCharges\": {\n \"active\": true,\n \"qty\": 123\n }\n },\n \"charge\": {\n \"frequencyDays\": 1,\n \"deniedIntervalDays\": 1,\n \"maxDeniedAttempts\": 1,\n \"invoiceIdentification\": \"<string>\",\n \"paymentMethod\": [\n {\n \"active\": true,\n \"installments\": [\n {\n \"installment\": 123,\n \"fee\": 1,\n \"totalAmount\": 1,\n \"installmentAmount\": 1\n }\n ]\n }\n ],\n \"routes\": []\n },\n \"product\": {\n \"price\": 1,\n \"originalPrice\": 1,\n \"title\": \"<string>\",\n \"photo\": \"<string>\",\n \"warranty\": 1,\n \"description\": \"<string>\",\n \"SKU\": \"<string>\"\n },\n \"unsubscription\": {\n \"overdueDays\": 1\n },\n \"checkout\": {\n \"header\": {\n \"color\": \"<string>\",\n \"fixed\": true,\n \"active\": true,\n \"logo\": \"<string>\"\n },\n \"topBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"sideBanner\": {\n \"active\": true,\n \"url\": \"<string>\"\n },\n \"contact\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"terms\": {\n \"active\": true,\n \"text\": \"<string>\"\n },\n \"privacyterms\": {\n \"active\": true,\n \"linkTermsUse\": \"<string>\",\n \"linkPrivacyPolicy\": \"<string>\"\n },\n \"tracking\": {\n \"meta\": \"<string>\",\n \"gtm\": \"<string>\"\n },\n \"color\": {\n \"textPrimary\": \"<string>\",\n \"secondary\": \"<string>\",\n \"background\": \"<string>\",\n \"primary\": \"<string>\",\n \"textSecondary\": \"<string>\"\n },\n \"countdown\": {\n \"time\": 123,\n \"fixed\": true,\n \"active\": true,\n \"color\": {\n \"background\": \"<string>\",\n \"text\": \"<string>\"\n }\n },\n \"faq\": {\n \"active\": true,\n \"list\": [\n {\n \"question\": \"<string>\",\n \"answer\": \"<string>\"\n }\n ]\n }\n },\n \"send\": {\n \"active\": true,\n \"list\": [\n {\n \"active\": true,\n \"id\": \"<string>\",\n \"integrationId\": \"<string>\",\n \"linkAccess\": \"<string>\",\n \"name\": \"<string>\",\n \"productId\": \"<string>\"\n }\n ]\n },\n \"discount\": {\n \"list\": []\n },\n \"notification\": {\n \"overdueCharge\": {\n \"email\": true\n },\n \"paidCharge\": {\n \"email\": true,\n \"message\": \"<string>\"\n }\n },\n \"_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"_id": "product_id",
"active": true
}{
"error_messages": [
{
"msg": "Payload invalido.",
"type": "field",
"path": "companyId",
"location": "body"
}
],
"code": "ZodValidationException",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Unauthorized."
}
],
"code": "unauthorized",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Forbidden."
}
],
"code": "forbidden",
"path": "/v1/product",
"metadata": {}
}{
"error_messages": [
{
"msg": "Unknown server error."
}
],
"code": "unknown_server_error",
"path": "/v1/product",
"metadata": {}
}Authorizations
API key no formato keyId.secret.
Body
ID da empresa dona do produto.
Indica se o produto esta ativo.
Indica exclusao logica do produto.
Configuracoes gerais do produto.
Show child attributes
Show child attributes
Regras de cobranca do produto, como frequencia, tentativas e metodos de pagamento.
Show child attributes
Show child attributes
Dados comerciais do produto, como title, price e warranty.
Show child attributes
Show child attributes
Regra de cancelamento da assinatura vinculada ao produto.
Show child attributes
Show child attributes
Configuracoes de checkout do produto.
Show child attributes
Show child attributes
Configuracoes de envio ou entrega associadas ao produto.
Show child attributes
Show child attributes
Configuracoes de desconto do produto.
Show child attributes
Show child attributes
Configuracoes de notificacao do produto.
Show child attributes
Show child attributes
ID do produto que sera atualizado.
Response
Produto atualizado.
ID do produto.
ID da empresa dona do produto.
Indica se o produto esta ativo.
Indica exclusao logica do produto.
Dados comerciais do produto, como title e price.
Regras de cobranca do produto.
Configuracoes gerais do produto.
Regra de cancelamento vinculada ao produto.
Show child attributes
Show child attributes
Was this page helpful?
