Remove Submerchant Markup
curl --request DELETE \
--url https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups', 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.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"message": "Markup removed successfully.",
"deleted": 3
}
{
"message": "Markup not found."
}
{
"message": "The given data was invalid.",
"errors": {
"subMerchantId": [
"The subaccount 7777 does not belong to this account."
]
}
}
{
"error": "Failed to remove markup."
}
Submerchant
Remove Submerchant Markup
Remove the markup configuration of a submerchant.
DELETE
/
v2
/
account
/
{merchantId}
/
submerchants
/
{subMerchantId}
/
markups
Remove Submerchant Markup
curl --request DELETE \
--url https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups', 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.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.wepayout.com.br/v2/account/{merchantId}/submerchants/{subMerchantId}/markups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"message": "Markup removed successfully.",
"deleted": 3
}
{
"message": "Markup not found."
}
{
"message": "The given data was invalid.",
"errors": {
"subMerchantId": [
"The subaccount 7777 does not belong to this account."
]
}
}
{
"error": "Failed to remove markup."
}
Remove Submerchant Markup
Use this endpoint to remove all of a submerchant’s own markup configurations, for every product and payment method.After the removal, the submerchant’s transactions use the merchant’s global markup again. An inline
markup sent in the request still takes priority.Path Parameters
integer
required
ID of the merchant (parent account). It must be one of the authenticated user’s companies.
integer
required
ID of the submerchant. It must be a submerchant of
merchantId.Request Example
cURL
curl -X DELETE "https://api.sandbox.wepayout.com.br/v2/account/123/submerchants/1234/markups" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Accept: application/json"
Response
string
Confirmation message.
integer
Number of markup configurations removed.
{
"message": "Markup removed successfully.",
"deleted": 3
}
{
"message": "Markup not found."
}
{
"message": "The given data was invalid.",
"errors": {
"subMerchantId": [
"The subaccount 7777 does not belong to this account."
]
}
}
{
"error": "Failed to remove markup."
}
Related Resources
Configure Submerchant Markup
Set the markup of a submerchant
List Merchant Markups
View the global markup
Was this page helpful?

