TikTok
Configure the TikTok warehouse used for inventory publishing
Sets the TikTok logistics warehouse that inventory publishing uses for the company’s TikTok Shop connection. tiktok_warehouse_id must match a Fluid warehouse this company has mapped to that TikTok warehouse; an unmapped id returns 422 and leaves the connection unchanged. Requires a company admin token with the company_settings.update permission. Returns the updated connection.
PATCH
/
api
/
v202506
/
tiktok
/
connection
Configure the TikTok warehouse used for inventory publishing
curl --request PATCH \
--url https://api.fluid.app/api/v202506/tiktok/connection \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"tiktok_warehouse_id": "7302198465731028741"
}
'import requests
url = "https://api.fluid.app/api/v202506/tiktok/connection"
payload = { "tiktok_warehouse_id": "7302198465731028741" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({tiktok_warehouse_id: '7302198465731028741'})
};
fetch('https://api.fluid.app/api/v202506/tiktok/connection', 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.fluid.app/api/v202506/tiktok/connection",
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([
'tiktok_warehouse_id' => '7302198465731028741'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.fluid.app/api/v202506/tiktok/connection"
payload := strings.NewReader("{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.fluid.app/api/v202506/tiktok/connection")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/v202506/tiktok/connection")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}"
response = http.request(request)
puts response.read_body{
"connection": {
"id": 3342,
"shop_id": "7494851036219083526",
"shop_name": "Dunder Mifflin Paper Company",
"region": "US",
"seller_type": "LOCAL",
"status": "connected",
"access_token_expires_at": "2026-10-07T15:32:08.000Z",
"refresh_token_expires_at": "2027-03-13T15:32:08.000Z",
"last_error": null,
"connected_at": "2026-09-14T15:32:08.000Z",
"disconnected_at": null,
"tiktok_warehouse_id": "7302198465731028741"
},
"status": 200,
"meta": {
"request_uuid": "8b4e2f71-3c9a-4d6e-b1f0-5a7c9e2d4b18",
"timestamp": "2026-09-30T16:42:11Z"
}
}{
"message": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
⌘I
Configure the TikTok warehouse used for inventory publishing
curl --request PATCH \
--url https://api.fluid.app/api/v202506/tiktok/connection \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"tiktok_warehouse_id": "7302198465731028741"
}
'import requests
url = "https://api.fluid.app/api/v202506/tiktok/connection"
payload = { "tiktok_warehouse_id": "7302198465731028741" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({tiktok_warehouse_id: '7302198465731028741'})
};
fetch('https://api.fluid.app/api/v202506/tiktok/connection', 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.fluid.app/api/v202506/tiktok/connection",
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([
'tiktok_warehouse_id' => '7302198465731028741'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.fluid.app/api/v202506/tiktok/connection"
payload := strings.NewReader("{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.fluid.app/api/v202506/tiktok/connection")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/v202506/tiktok/connection")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"tiktok_warehouse_id\": \"7302198465731028741\"\n}"
response = http.request(request)
puts response.read_body{
"connection": {
"id": 3342,
"shop_id": "7494851036219083526",
"shop_name": "Dunder Mifflin Paper Company",
"region": "US",
"seller_type": "LOCAL",
"status": "connected",
"access_token_expires_at": "2026-10-07T15:32:08.000Z",
"refresh_token_expires_at": "2027-03-13T15:32:08.000Z",
"last_error": null,
"connected_at": "2026-09-14T15:32:08.000Z",
"disconnected_at": null,
"tiktok_warehouse_id": "7302198465731028741"
},
"status": 200,
"meta": {
"request_uuid": "8b4e2f71-3c9a-4d6e-b1f0-5a7c9e2d4b18",
"timestamp": "2026-09-30T16:42:11Z"
}
}{
"message": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"cursor": "<string>",
"limit": 123,
"prev_cursor": "<string>",
"next_cursor": "<string>",
"total_count": 123
}
}
}