Search H&M France products
Automatically search H&M France products on hm.com. Search the H&M France shop (hm.com/fr_fr, prices in euros) by free text and return one page of results of about 36 products: id, name, price, colors, sizes with their variant ids and stock, image and link, plus the total count, the page count and the filters the site offers. Page through with page; stop when has_next_page is false. Pass a product id to Get H&M France product, or a variant id (product id plus size code) to Add H&M France product to cart.
Inputs
query requiredFree-text search, for example "t-shirt blanc".
page optionalResult page, 1-based. Stop when has_next_page is false.
Default: 1Output
page requireditems requiredquery requiredfilters requiredhas_next_page requiredtotal_pages optionaltotal_results optionalFAQ
Remove H&M France product from cart
Remove a product from the H&M France guest cart of this browser (hm.com/fr_fr), whatever its quantity, and return what is left: each line with variant id, product id, name, brand, size, color, quantity, unit price and line price in euros, plus the item count and the items subtotal. Pass a variant id (product id plus size code) to remove that size, or a product id to remove every size of it. A product that is not in the cart is reported with removed false and the cart unchanged, not as a failure.
List H&M France cart items
List the items in the H&M France cart of this browser (hm.com/fr_fr), as the site holds it: for each line the variant id, product id, name, brand, size, color, quantity, unit price and line price in euros, plus the item count and the items subtotal (delivery not included). The cart is the guest cart of the browser, so no sign-in is needed. An empty cart returns an empty list and a zero count.
Add H&M France product to cart
Add one size of an H&M France product (hm.com/fr_fr) to the guest cart of this browser, with a quantity from 1 to 10, and return the cart as the site holds it afterwards: each line with variant id, product id, name, brand, size, color, quantity, unit price and line price in euros, plus the item count and the items subtotal. Pass the variant id (product id plus size code, from Search or Get H&M France product). Given only a product id or a link, it fails with the list of sizes and their variant ids. A size that is out of stock fails with an error. Nothing is paid or ordered.
