Change an item
const url = 'https://api.threadkite.app/v1/items/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = { method: 'PATCH', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"locationId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","attributes":{"title":"Merino jumper","description":"example","link":"https://example.com","imageLinks":["https://example.com"],"price":{"amountMinor":1299500,"currency":"GBP"},"salePrice":{"amountMinor":1299500,"currency":"GBP"},"availability":"in_stock","condition":"new","brand":"example","gtin":"example","mpn":"example","sku":"example","googleProductCategory":"example","productType":"example","itemGroupId":"example","size":"example","colour":"example","material":"example","pattern":"example","customLabel0":"example","customLabel1":"example","customLabel2":"example","customLabel3":"example","customLabel4":"example"},"billing":"one_off","addOn":true,"addOnFor":["example"]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://api.threadkite.app/v1/items/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "locationId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "attributes": { "title": "Merino jumper", "description": "example", "link": "https://example.com", "imageLinks": [ "https://example.com" ], "price": { "amountMinor": 1299500, "currency": "GBP" }, "salePrice": { "amountMinor": 1299500, "currency": "GBP" }, "availability": "in_stock", "condition": "new", "brand": "example", "gtin": "example", "mpn": "example", "sku": "example", "googleProductCategory": "example", "productType": "example", "itemGroupId": "example", "size": "example", "colour": "example", "material": "example", "pattern": "example", "customLabel0": "example", "customLabel1": "example", "customLabel2": "example", "customLabel3": "example", "customLabel4": "example" }, "billing": "one_off", "addOn": true, "addOnFor": [ "example" ] }'Attribute fields sent replace the current ones and null clears an optional field; the result is validated as a whole.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”object
object
Google/Meta title
Example
Merino jumperGoogle/Meta description
Product page. Google/Meta link
Main image first. Google/Meta image_link and additional_image_link
Google/Meta price
object
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPobject
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPGoogle/Meta availability
Google/Meta condition
Google/Meta brand
GTIN-8, 12, 13 or 14. Google/Meta gtin
Google/Meta mpn
Your own stock code
Google/Meta google_product_category
Google/Meta product_type
Shared by variants. Google/Meta item_group_id
Google/Meta size
Google/Meta color
Google/Meta material
Google/Meta pattern
Google/Meta custom_label_0
Google/Meta custom_label_1
Google/Meta custom_label_2
Google/Meta custom_label_3
Google/Meta custom_label_4
object
Advert title; made from make, model and derivative when left out. Google/Meta title
Google/Meta description
Number plate. Meta vehicle_registration_plate
Example
AB12 CDEGoogle/Meta vin
Example
WF0XXXGCDX1234567Google brand, Meta make
Example
FordGoogle/Meta model
Example
FocusFull version name
Example
1.0 EcoBoost Titanium 5drGoogle/Meta trim
Example
TitaniumGoogle/Meta year
Example
2019First registration date, YYYY-MM-DD
Google mileage, Meta mileage.value and .unit
object
Example
24000Example
miGoogle condition and certified_pre_owned, Meta state_of_vehicle
Google engine, Meta fuel_type
Example
PetrolMeta transmission
Example
ManualMeta drivetrain
Exterior colour. Google color, Meta exterior_color
Example
BlueMeta interior_color
Example
BlackGoogle/Meta body_style
Example
HatchbackGoogle/Meta price
object
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPobject
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPobject
Example
£249 a month, 48 months, 9.9% APR representativeobject
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPobject
Amount in minor units (pence, cents)
Example
1299500ISO 4217
Example
GBPMain image first. Google image_link/additional_image_link, Meta image[n].url
Advert page. Google link, Meta url
Google/Meta availability
How the price is charged: one_off (once, the default for a new item), monthly or annual. Left out, an existing item keeps its own
Example
monthlyUsually sold as an add-on to something else (suggested when adding add-ons)
The item types it is usually added to; empty means anything
Responses
Section titled “Responses”object
Where the item came from: manual, csv, api or an integration key
The item’s id in its source
From the attributes
The availability: in_stock, out_of_stock, preorder or backorder for products; an industry pack’s item types have their own
object
Amount in minor units (pence, cents)
ISO 4217
How the price is charged: one_off (once), monthly (every month) or annual (every year)
Image links, main image first
When it was removed from the catalogue (no longer in stock). Removed items stay on the leads and threads that mention them
Advert or product page
Usually sold as an add-on to something else (a warranty, delivery, an onboarding package). Suggestions only
The item types it is usually added to; empty means anything
object
Google/Meta title
Google/Meta description
Product page. Google/Meta link
Main image first. Google/Meta image_link and additional_image_link
Google/Meta price
object
Amount in minor units (pence, cents)
ISO 4217
Google/Meta sale_price
object
Amount in minor units (pence, cents)
ISO 4217
Google/Meta availability
Google/Meta condition
Google/Meta brand
GTIN-8, 12, 13 or 14. Google/Meta gtin
Google/Meta mpn
Your own stock code
Google/Meta google_product_category
Google/Meta product_type
Shared by variants. Google/Meta item_group_id
Google/Meta size
Google/Meta color
Google/Meta material
Google/Meta pattern
Google/Meta custom_label_0
Google/Meta custom_label_1
Google/Meta custom_label_2
Google/Meta custom_label_3
Google/Meta custom_label_4
object
Where the item came from: manual, csv, api or an integration key
The item’s id in its source
From the attributes
The availability: in_stock, out_of_stock, preorder or backorder for products; an industry pack’s item types have their own
object
Amount in minor units (pence, cents)
ISO 4217
How the price is charged: one_off (once), monthly (every month) or annual (every year)
Image links, main image first
When it was removed from the catalogue (no longer in stock). Removed items stay on the leads and threads that mention them
Advert or product page
Usually sold as an add-on to something else (a warranty, delivery, an onboarding package). Suggestions only
The item types it is usually added to; empty means anything
object
Advert title; made from make, model and derivative when left out. Google/Meta title
Google/Meta description
Number plate. Meta vehicle_registration_plate
Google/Meta vin
Google brand, Meta make
Google/Meta model
Full version name
Google/Meta trim
Google/Meta year
First registration date, YYYY-MM-DD
Google mileage, Meta mileage.value and .unit
object
Google condition and certified_pre_owned, Meta state_of_vehicle
Google engine, Meta fuel_type
Meta transmission
Meta drivetrain
Exterior colour. Google color, Meta exterior_color
Meta interior_color
Google/Meta body_style
Google/Meta price
object
Amount in minor units (pence, cents)
ISO 4217
Google/Meta sale_price
object
Amount in minor units (pence, cents)
ISO 4217
object
object
Amount in minor units (pence, cents)
ISO 4217
object
Amount in minor units (pence, cents)
ISO 4217
Main image first. Google image_link/additional_image_link, Meta image[n].url
Advert page. Google link, Meta url
Google/Meta availability
Example
{ "source": "my-dms", "externalId": "SKU-1042", "title": "Oak dining table", "status": "in_stock", "price": { "amountMinor": 1299500, "currency": "GBP" }, "billing": "one_off", "addOnFor": [ "product" ], "attributes": { "title": "Merino jumper", "price": { "amountMinor": 1299500, "currency": "GBP" }, "salePrice": { "amountMinor": 1299500, "currency": "GBP" }, "availability": "in_stock", "condition": "new" }, "type": "product"}object
Stable machine-readable reason
object
Dotted path inside the item, e.g. attributes.price.amountMinor
Example
{ "statusCode": 400, "code": "invalid_attributes", "message": "Enter the make", "errors": [ { "message": "Enter the make" } ]}Missing or invalid API key
object
Stable machine-readable reason
With code invalid: every problem with the request, by field (message is the first)
object
Dotted path inside the item, e.g. attributes.price.amountMinor
Example
{ "statusCode": 403, "code": "forbidden", "message": "You do not have permission to do that.", "errors": [ { "message": "Enter the make" } ]}The organisation is on the Free plan (code upgrade_required)
object
Stable machine-readable reason
The feature that needs Pro
Where to upgrade or pay, in the web app
Example
{ "statusCode": 402, "code": "upgrade_required", "message": "Connections are part of Pro. Upgrade to connect texts, calls and more.", "feature": "extraSeats", "upgradePath": "/settings/billing"}The key does not have the scope (or the person the permission)
object
Stable machine-readable reason
With code invalid: every problem with the request, by field (message is the first)
object
Dotted path inside the item, e.g. attributes.price.amountMinor
Example
{ "statusCode": 403, "code": "forbidden", "message": "You do not have permission to do that.", "errors": [ { "message": "Enter the make" } ]}object
Stable machine-readable reason
With code invalid: every problem with the request, by field (message is the first)
object
Dotted path inside the item, e.g. attributes.price.amountMinor
Example
{ "statusCode": 403, "code": "forbidden", "message": "You do not have permission to do that.", "errors": [ { "message": "Enter the make" } ]}Rate limit reached
object
Stable machine-readable reason
Seconds until another request will be accepted
Example
{ "statusCode": 429, "code": "rate_limited", "message": "Too many requests. Each key can make 120 requests a minute; try again in 12 seconds.", "retryAfter": 12}