.webm file to a secure presigned storage URL associated with your account, then create an analysis that references that upload. Once processing completes, you receive per-frame attention predictions you can use to evaluate your video content.
Video files must meet the following requirements before upload:
- Format:
.webmonly - Size: 100 MB or less
- Duration: 60 seconds or less
Set up authentication
Install the
requests library if you haven’t already, then define a BearerTokenAuth helper class that attaches your API token to every request. Create a persistent session so your credentials carry across all subsequent calls.Request a presigned upload URL
Before you can upload your video, you need a presigned URL pointing to the secure storage bucket associated with your EyeQuant account. Fetch one by sending a The
GET request to /v2/upload-urls.url value in the response is the destination for your video file in the next step.Upload the video file
Send a
PUT request directly to the presigned URL with your video’s raw binary content as the request body. Note that this request goes to the presigned storage URL — not to the EyeQuant API — so you do not need to include your API token here.Create the analysis
With the video now uploaded, create a video analysis by sending a Save the
POST request to /v2/analyses/video. Pass the same presigned upload_url as the content field so EyeQuant knows where to find your file.location value from the response — you’ll poll that URL to track progress.Video analysis may take several minutes to complete, depending on the duration and file size of your upload. Poll the status endpoint every 30 seconds rather than more frequently to avoid unnecessary requests.
