curl --request POST \
--url https://api.merchantops.ai/api/pricing/batches/{key}/publish-now \
--header 'Content-Type: application/json' \
--data '
{
"ignore_effective_date": false
}
'import requests
url = "https://api.merchantops.ai/api/pricing/batches/{key}/publish-now"
payload = { "ignore_effective_date": False }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({ignore_effective_date: false})
};
fetch('https://api.merchantops.ai/api/pricing/batches/{key}/publish-now', 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.merchantops.ai/api/pricing/batches/{key}/publish-now",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'ignore_effective_date' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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.merchantops.ai/api/pricing/batches/{key}/publish-now"
payload := strings.NewReader("{\n \"ignore_effective_date\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.merchantops.ai/api/pricing/batches/{key}/publish-now")
.header("Content-Type", "application/json")
.body("{\n \"ignore_effective_date\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.merchantops.ai/api/pricing/batches/{key}/publish-now")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"ignore_effective_date\": false\n}"
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Publish Batch Now
Manually trigger publishing for an approved batch, bypassing the effective_date schedule. Useful for testing and emergency repricing.
Pass {"ignore_effective_date": true} to force-publish a batch whose
effective date has not arrived. The effective date is unchanged, and the
scheduled publish will not fire again.
Returns on success.
curl --request POST \
--url https://api.merchantops.ai/api/pricing/batches/{key}/publish-now \
--header 'Content-Type: application/json' \
--data '
{
"ignore_effective_date": false
}
'import requests
url = "https://api.merchantops.ai/api/pricing/batches/{key}/publish-now"
payload = { "ignore_effective_date": False }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({ignore_effective_date: false})
};
fetch('https://api.merchantops.ai/api/pricing/batches/{key}/publish-now', 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.merchantops.ai/api/pricing/batches/{key}/publish-now",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'ignore_effective_date' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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.merchantops.ai/api/pricing/batches/{key}/publish-now"
payload := strings.NewReader("{\n \"ignore_effective_date\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.merchantops.ai/api/pricing/batches/{key}/publish-now")
.header("Content-Type", "application/json")
.body("{\n \"ignore_effective_date\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.merchantops.ai/api/pricing/batches/{key}/publish-now")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"ignore_effective_date\": false\n}"
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Path Parameters
Cookies
Body
Body for POST /batches/{key}/publish-now.
ignore_effective_date force-publishes a batch whose effective date is
still in the future — reviewers previewing next month's prices on a staging
target, or an emergency reprice. The batch's effective_date is NOT
changed. Because the batch lands in publishing_status="published", the
60-second scheduler will not publish it again on that date
(claim_ready_batches claims only missing/None/ready/failed), so an early
publish CONSUMES the scheduled one. Re-ship with the Republish action.
Every other guard still applies: a targetless batch is refused, and an unpublished catalog-batch dependency still blocks.
Response
Successful Response