...
Note |
---|
Please remember that the type of custom products currently available for rendering on-the-fly are Wall Murals. Other product types can be added upon request. |
Step 1. Upload custom interior and get uuid of this interior
Use next endpoint to upload custom interior: https://rni.wizart.ai/api/rooms
.
...
To render custom products you need know UUID of the room (second line).
Step 2. Apply product from your catalogue in the interior
Example of request:
Code Block |
---|
curl --location --request POST 'https://rni.wizart.ai/apply/custom?hash={{ HASH }}' \ --header 'device-token: {{ DEVICE_TOKEN }}' \ --header 'authorization: {{ API_KEY }}' \ --header 'Content-Type: application/json' \ --data-raw '{"data":{"type":"products","attributes":{"type":"wall_mural","name":"Murals 02","vendor_code":"Murals 02","image_path":"{{ PATH_TO_IMAGE }}","preview_path":"","link":"","width":"3","height":"5","unit":"m","repeatable":1,"surface":["wall"],"height_feet":0,"height_inch":0,"width_feet":0,"width_inch":0},"relationships":{"selected_surfaces":{"data":[{"type":"walls","id":0}]},"rooms":{"data":{"type":"rooms","id":"{{ ROOM_UUID }}"}},"share":null}},"included":[]}' |
...
{{ HASH }} - you need to generate this hash by MD5 hash of HTTP request body;
{{ DEVICE_TOKEN }} - device ID (any generated unique key);
{{ API_KEY }} - authorization token provided by WIZART;
{{ PATH_TO_IMAGE }} - path to the product interior image;
{{ ROOM_UUID }} - UUID that you retrieved from Step 1.
...