Detach assets from order
DELETE
/orders/{id}/detach_assetsCosts 2 rate-limit points · Rate limits
Remove one or more custom-attached assets from an order. Only affects assets attached via the attach_assets endpoint: product-level assets linked through digital products are not affected.
Beta: this endpoint is in active development.
Path parameters
idstringRequiredThe order ID
Headers
X-Auth-TokenstringRequiredAPI key for authentication
Request body
asset_idsarray of stringsRequiredArray of asset UUIDs to detach from the order
Errors
404
Resource not found
422
Validation failed
DELETE/orders/{id}/detach_assets
curl -X DELETE "https://app.filemonk.io/api/v1/external/orders/{id}/detach_assets" \
-H "X-Auth-Token: $FILEMONK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"asset_ids": [
"f1e2d3c4-b5a6-7890-fedc-ba0987654321"
]
}'const res = await fetch("https://app.filemonk.io/api/v1/external/orders/{id}/detach_assets", {
method: "DELETE",
headers: {
"X-Auth-Token": process.env.FILEMONK_API_KEY,
"Content-Type": "application/json",
},
body: JSON.stringify({
"asset_ids": [
"f1e2d3c4-b5a6-7890-fedc-ba0987654321"
]
}),
});
const data = await res.json();import os
import requests
res = requests.delete(
"https://app.filemonk.io/api/v1/external/orders/{id}/detach_assets",
headers={"X-Auth-Token": os.environ["FILEMONK_API_KEY"]},
json={
"asset_ids": [
"f1e2d3c4-b5a6-7890-fedc-ba0987654321"
]
},
)
data = res.json()require "net/http"
require "json"
uri = URI("https://app.filemonk.io/api/v1/external/orders/{id}/detach_assets")
req = Net::HTTP::Delete.new(uri, "X-Auth-Token" => ENV["FILEMONK_API_KEY"], "Content-Type" => "application/json")
req.body = {
asset_ids: [
"f1e2d3c4-b5a6-7890-fedc-ba0987654321"
]
}.to_json
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |http| http.request(req) }
data = JSON.parse(res.body)Response
No body
{
"error": "API key is required"
}{
"error": "Resource not found"
}No body
No body