Set environment variables
<your-unstructured-api-url>
with the Unstructured Partition Endpoint URL, which is https://api.unstructuredapp.io/general/v0/general
<your-unstructured-api-key>
with your Unstructured API key, which you generated earlier on this page.Run the curl command
curl
command, replacing <path/to/file>
with the path to the source file on your local machine.If the source file is not a PDF file, then remove ;type=application/pdf
from the final --form
option in this command.Examine the results
curl
command, the results are printed to your terminal or Command Prompt. The command might take several
minutes to complete.By default, the JSON is printed without indenting or other whitespace. You can pretty-print the JSON output by using utilities such as jq in future command runs.You can also pipe the JSON output to a local file by using the curl
option -o, —output <file> in future command runs.SCARF_NO_ANALYTICS=true
before running any commands that call Unstructured hosted APIs.