Post Case Message
curl --request POST \
--url https://api.zinc.com/cases/{case_id}/messages \
--header 'Authorization: <api-key>' \
--header 'Content-Type: multipart/form-data' \
--form body=import requests
url = "https://api.zinc.com/cases/{case_id}/messages"
payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--"
headers = {
"Authorization": "<api-key>",
"Content-Type": "multipart/form-data"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const form = new FormData();
form.append('body', '');
const options = {method: 'POST', headers: {Authorization: '<api-key>'}};
options.body = form;
fetch('https://api.zinc.com/cases/{case_id}/messages', 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.zinc.com/cases/{case_id}/messages",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: multipart/form-data"
],
]);
$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.zinc.com/cases/{case_id}/messages"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.zinc.com/cases/{case_id}/messages")
.header("Authorization", "<api-key>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zinc.com/cases/{case_id}/messages")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reason": "not_received",
"status": "open",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"return_request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"credited_amount": 0,
"opened_by_name": "<string>",
"closed_at": "2023-11-07T05:31:56Z",
"messages": []
}{
"error": {
"code": "unauthorized",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "unauthorized",
"message": "<string>",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Cases
Post Case Message
Reply on a Zinc support case, with optional attachments. Reopens a closed case.
POST
/
cases
/
{case_id}
/
messages
Post Case Message
curl --request POST \
--url https://api.zinc.com/cases/{case_id}/messages \
--header 'Authorization: <api-key>' \
--header 'Content-Type: multipart/form-data' \
--form body=import requests
url = "https://api.zinc.com/cases/{case_id}/messages"
payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--"
headers = {
"Authorization": "<api-key>",
"Content-Type": "multipart/form-data"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const form = new FormData();
form.append('body', '');
const options = {method: 'POST', headers: {Authorization: '<api-key>'}};
options.body = form;
fetch('https://api.zinc.com/cases/{case_id}/messages', 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.zinc.com/cases/{case_id}/messages",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: multipart/form-data"
],
]);
$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.zinc.com/cases/{case_id}/messages"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.zinc.com/cases/{case_id}/messages")
.header("Authorization", "<api-key>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.zinc.com/cases/{case_id}/messages")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"body\"\r\n\r\n\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"order_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reason": "not_received",
"status": "open",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"return_request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"credited_amount": 0,
"opened_by_name": "<string>",
"closed_at": "2023-11-07T05:31:56Z",
"messages": []
}{
"error": {
"code": "unauthorized",
"message": "<string>",
"details": {}
}
}{
"error": {
"code": "unauthorized",
"message": "<string>",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Reply on a support case. Like Create Case, this is a multipart form:
curl -X POST "https://api.zinc.com/cases/3f2c9a8e-1b4d-4e6f-9a7b-2c8d5e1f0a3b/messages" \
-H "Authorization: Bearer <your_api_key>" \
-F "body=Here's a photo of the shipping label." \
-F "files=@label.jpg"
- body: your message, up to 5,000 characters. It can be empty if you attach at least one file.
- files (optional): up to 5 attachments, 25 MB each, as JPEG, PNG, WebP, HEIC or PDF.
Status after a reply
A reply moves the case toopen, which means it’s back with Zinc support.
Replying on a closed case reopens it, and the thread gets a Case reopened line. That’s allowed only inside the order’s case window (see When a case can be opened):
- Past the window, the reply fails with
400,code: "case_not_allowed"anddetails.reason: "window_closed". Nothing is posted. - If another case on the same order has been opened since this one closed, the reply fails with
409. An order can have only one open case, anddetails.case_idnames the open one. Reply there instead.
Other errors
| Status | code | Cause |
|---|---|---|
404 | not_found | No case with that ID, or it belongs to another team |
413 | A file is over 25 MB | |
415 | A file isn’t JPEG, PNG, WebP, HEIC or PDF | |
422 | validation_error | No message and no files, a message over 5,000 characters, or more than 5 files |
Authorizations
Zinc API key (Bearer zn_...)
Headers
Path Parameters
Response
Successful Response
What a support case is about. Routing and reporting only — no reason triggers automation.
Available options:
not_received, missing_item, late, damaged_or_wrong_item, cancellation, address_change, return, billing, other open — waiting on Zinc. waiting_on_customer — Zinc replied and is waiting on you. on_hold — waiting on the retailer or carrier. closed — resolved; replying reopens it within the case window.
Available options:
open, waiting_on_customer, on_hold, closed Total wallet credit issued from this case, in cents (net of reversals).
Who opened the case: a teammate's name, or Zinc support when Zinc reached out. (The case.created webhook's opened_by is the side instead: customer or zinc.)
Show child attributes
Show child attributes

