1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
const axios = require('axios');
const api_key = "YOUR API KEY";
const url = "https://api.segmind.com/workflows/662b8998ceb95bf846a51104-v1";
const data = {
input_image: "publicly accessible image link"
};
axios.post(url, data, {
headers: {
'x-api-key': api_key,
'Content-Type': 'application/json'
}
}).then((response) => {
console.log(response.data);
});
1
2
3
4
5
{
"poll_url": "<base_url>/requests/<some_request_id>",
"request_id": "some_request_id",
"status": "QUEUED"
}
You can poll the above link to get the status and output of your request.
1
2
3
{
"output_image": "image in URL Format"
}
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Product Photography Furniture Indoor & Outdoor enables the transformation of existing product images by generating new, contextually suitable backgrounds for both indoor and outdoor furniture items. This technical workflow enhances product presentation by offering a seamless way to adapt product visuals to different settings, optimizing them for varied marketing and advertising needs.
The workflow employs a detailed process to refresh and extend the appearance of furniture product images through the use of advanced inpainting and outpainting techniques:
Fooocus Inpainting: This step is crucial for altering the existing background of any given furniture item, such as a sofa or bench. The inpainting technology intelligently fills areas around the furniture, creating a new backdrop that suits the intended indoor or outdoor scene.
Fooocus Outpaint: Once the background is updated, the outpaint function expands the image borders. This is particularly useful for ensuring that the new background seamlessly integrates with the furniture, providing a complete and expansive image that can be readily used in any promotional material.
Upload an Image: Start by uploading a high-quality photo of the furniture item that you wish to modify.
Background Generation: Allow the Fooocus inpainting to process the image, generating a new background that aligns with your specified indoor or outdoor setting.
Expand Image Borders: Finally, utilize the Fooocus outpaint function to expand the photo borders, creating a finalized image that is ready for use in diverse applications.
E-commerce Platforms: Enhance product listings by providing visually appealing backgrounds that highlight furniture in contextually appropriate settings, aiding consumer visualization.
Marketing Campaigns: Create diverse imagery for catalogs, ads, and promotional materials that showcase furniture in various indoor and outdoor environments.
Interior Design Portfolios: Enrich visual presentations with varied settings for furniture pieces, supporting the demonstration of aesthetic versatility in design portfolios.
Social Media Promotions: Adapt product imagery for different social media platforms, ensuring that each piece of furniture is presented in its best setting to attract potential buyers.