|
| 1 | +--- |
| 2 | +title: HuntAPI |
| 3 | +description: Download videos and audio from public video URLs |
| 4 | +integration: |
| 5 | + type: "huntapi" |
| 6 | + color: "#FFFFFF" |
| 7 | +--- |
| 8 | + |
| 9 | +import { ReferenceDetails } from "@/components/ui/reference-details" |
| 10 | + |
| 11 | + |
| 12 | +{/* MANUAL-CONTENT-START:intro */} |
| 13 | +[HuntAPI](https://www.huntapi.com/) downloads video and audio from public video URLs, with the video's metadata. |
| 14 | + |
| 15 | +With the HuntAPI block, you can: |
| 16 | + |
| 17 | +- **Download videos**: start a download in a chosen quality and format, with or without sound |
| 18 | +- **Extract audio**: start extracting a video's audio track as MP3, M4A or WAV |
| 19 | +- **Get the file**: check a download job and, once it completes, get the link to the file with the video's title, duration, uploader and view counts |
| 20 | + |
| 21 | +Downloads run as jobs: Download Video and Download Audio return a job ID, and Get Job returns the file link once the job's status is CompletedJob. |
| 22 | + |
| 23 | +Create an API key in the [HuntAPI dashboard](https://app.huntapi.com/) and paste it into the block. |
| 24 | + |
| 25 | +In Sim, the HuntAPI block lets your agents transcribe videos, archive content and collect video metadata. |
| 26 | +{/* MANUAL-CONTENT-END */} |
| 27 | + |
| 28 | +## Use the block [#usage-instructions] |
| 29 | + |
| 30 | +Start a download of a public video in a chosen quality and format, or extract its audio track, then check the job to get a link to the file with the video's title, duration, channel and view counts. |
| 31 | + |
| 32 | +## Actions |
| 33 | + |
| 34 | +### HuntAPI Download Video |
| 35 | + |
| 36 | +Start downloading a public video in a chosen quality and format. Returns a job ID; use Get Job to get the file link once the job completes. |
| 37 | + |
| 38 | +<ReferenceDetails> |
| 39 | + |
| 40 | +#### Input |
| 41 | + |
| 42 | +| Parameter | Type | Required | Description | |
| 43 | +| --------- | ---- | -------- | ----------- | |
| 44 | +| `url` | string | Yes | URL of the public video \(e.g., "https://www.youtube.com/watch?v=jNQXAC9IVRw") | |
| 45 | +| `videoQuality` | string | No | Quality: best, 1080p, 720p, 480p or 360p \(defaults to "best"\); videos over an hour are capped at 720p | |
| 46 | +| `videoFormat` | string | No | Preferred format: mp4, webm or mkv \(defaults to "mp4"\) | |
| 47 | +| `downloadType` | string | No | audio_video for the video with sound, video for the picture only \(defaults to "audio_video"\) | |
| 48 | +| `maxDuration` | number | No | Maximum duration in seconds; longer content is cut at this length | |
| 49 | +| `apiKey` | string | Yes | HuntAPI API key | |
| 50 | + |
| 51 | +#### Output |
| 52 | + |
| 53 | +| Parameter | Type | Description | |
| 54 | +| --------- | ---- | ----------- | |
| 55 | +| `jobId` | string | ID of the download job, to pass to Get Job | |
| 56 | + |
| 57 | +</ReferenceDetails> |
| 58 | + |
| 59 | +### HuntAPI Download Audio |
| 60 | + |
| 61 | +Start extracting the audio track of a public video as MP3 or another format. Returns a job ID; use Get Job to get the file link once the job completes. |
| 62 | + |
| 63 | +<ReferenceDetails> |
| 64 | + |
| 65 | +#### Input |
| 66 | + |
| 67 | +| Parameter | Type | Required | Description | |
| 68 | +| --------- | ---- | -------- | ----------- | |
| 69 | +| `url` | string | Yes | URL of the public video \(e.g., "https://www.youtube.com/watch?v=jNQXAC9IVRw") | |
| 70 | +| `audioQuality` | string | No | Quality: best, 320kbps, 256kbps or 128kbps \(defaults to "best"\) | |
| 71 | +| `audioFormat` | string | No | Preferred format: mp3, m4a or wav \(defaults to "mp3"\) | |
| 72 | +| `maxDuration` | number | No | Maximum duration in seconds; longer content is cut at this length | |
| 73 | +| `apiKey` | string | Yes | HuntAPI API key | |
| 74 | + |
| 75 | +#### Output |
| 76 | + |
| 77 | +| Parameter | Type | Description | |
| 78 | +| --------- | ---- | ----------- | |
| 79 | +| `jobId` | string | ID of the download job, to pass to Get Job | |
| 80 | + |
| 81 | +</ReferenceDetails> |
| 82 | + |
| 83 | +### HuntAPI Get Job |
| 84 | + |
| 85 | +Get a download job's status and progress and, once it completes, the link to the file with the video's metadata. |
| 86 | + |
| 87 | +<ReferenceDetails> |
| 88 | + |
| 89 | +#### Input |
| 90 | + |
| 91 | +| Parameter | Type | Required | Description | |
| 92 | +| --------- | ---- | -------- | ----------- | |
| 93 | +| `jobId` | string | Yes | The job ID returned by Download Video or Download Audio | |
| 94 | +| `apiKey` | string | Yes | HuntAPI API key | |
| 95 | + |
| 96 | +#### Output |
| 97 | + |
| 98 | +| Parameter | Type | Description | |
| 99 | +| --------- | ---- | ----------- | |
| 100 | +| `jobId` | string | ID of the download job | |
| 101 | +| `status` | string | Status of the job, CompletedJob once the file is ready | |
| 102 | +| `progress` | number | Progress of the job, from 0 to 100 | |
| 103 | +| `fileUrl` | string | Link to the downloaded file, once the job completes | |
| 104 | +| `createdAt` | string | When the job was created | |
| 105 | +| `completedAt` | string | When the job completed | |
| 106 | +| `durationMs` | number | Time the job took, in milliseconds | |
| 107 | +| `metadata` | object | Metadata of the video, once the job completes | |
| 108 | +| ↳ `title` | string | Title of the video | |
| 109 | +| ↳ `description` | string | Description of the video | |
| 110 | +| ↳ `duration` | number | Duration of the video in seconds | |
| 111 | +| ↳ `extension` | string | File extension of the download | |
| 112 | +| ↳ `thumbnail` | string | URL of the video thumbnail | |
| 113 | +| ↳ `uploader` | string | Name of the uploader | |
| 114 | +| ↳ `uploaderUrl` | string | URL of the uploader's page | |
| 115 | +| ↳ `viewCount` | number | Number of views | |
| 116 | +| ↳ `likeCount` | number | Number of likes | |
| 117 | +| ↳ `commentCount` | number | Number of comments | |
| 118 | +| ↳ `uploadDate` | number | Upload date as a Unix timestamp in seconds | |
| 119 | +| ↳ `webpageUrl` | string | URL of the video page | |
| 120 | + |
| 121 | +</ReferenceDetails> |
| 122 | + |
| 123 | + |
0 commit comments