I am Getting a Response from Slazzer API as an Error even After Converting the file into base64.
You’re complicating things by adding a web viewer. Can you use a text block (string) as the value for the
source_image_file* property and take this out of the web viewer event block? When you do that, what error do you get?
*The documentation shows that the property you need to use with base64 strings is source_image_base64.
Have you looked up error code 1003?
The documentation refer to F option in cURL but you are not reflecting it
curl -H 'API-KEY: YOUR_SLAZZER_API_KEY' -F 'source_image_file=@source_image_path' -f https://api.slazzer.com/v2.0/remove_image_background -o output.png
This means you have to emulate data form filling.
This is from the website of
slazzer. It requires a Content-Type of multipart/form-data
Can you please give me Code for the Request Body?
This topic is long but the last part of it deals with using a data property with two different methods, one of which uses url=: Trouble Using WhisperAPI
Please follow the instructions in the API Reference in the website. It clearly said you need to add multipart to your header.
I know it can feel like we know the answer and we’re just not telling you. It’s not that! It’s that POST API calls are complicated, especially when adding a file. And it would take a while to set up and test all of this on our end, especially since we don’t have an API key to use. So we’re left providing suggestions but @muneer is right and if you check the link to the topic I provided, you should be able to piece together a test. And then post new screenshots or a link to your project and we’ll go from there.
I van see two issues
You are using a block to get the URL of a file but the option says
source_image_base64which is not the correct option. Also remember if you use the url option then it will not work with files from your computer or mobile device. You have to use a fully qualifies names such as url that starts with
The body of the Web API is not a JSON object and you should not use
generate JSON from object. You should use the text style suggested by the API document.
How Do I Add INPUTS in text Style? Please Explain.
application/x-www-form-urlencoded as the content type and try
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.