@refkit/provider-openverse
v0.6.1
Published
Openverse provider satellite for refkit — CC/PD licensed image search, license-normalized.
Maintainers
Readme
@refkit/provider-openverse
Search Openverse (the CC / public-domain media aggregator) as license-normalized image and audio references — a provider satellite for refkit (use with @refkit/core).
- Source: Openverse (openverse.org)
- Auth: keyless
- Modality: image · audio
- License: per-item Creative Commons / public domain (CC version preserved in
rights.licenseVersion)
Usage
import { createRefkit } from '@refkit/core'
import { openverse, openverseAudio } from '@refkit/provider-openverse'
const refkit = createRefkit({ providers: [openverse(), openverseAudio()] })
const images = await refkit.search({ query: 'lion', modalities: ['image'] })
const audio = await refkit.search({ query: 'rain', modalities: ['audio'] })
// every result carries source + license + attribution + canonicalUrlopenverse() serves the image leg (source id openverse); add openverseAudio() for audio (source id openverse-audio).
What an audio result carries
thumbnailis the item's album art, and is unset when Openverse has none. It is never the waveform, which is JSON peak data.kindismusicorsound-effectwhen Openverse'scategorysays so (music,sound_effect); other categories (pronunciation,podcast,audiobook,news) and a missing one leave it unset. In live results (2026-10) only Jamendo-sourced items carried a mapped category (music); Freesound-sourced items carry none, so they have nokind.audio.durationSec(from milliseconds),audio.bitrateKbps(from bits per second) andaudio.sampleRateHz, when Openverse reports them. A missing, non-finite, zero or negative value leaves the field unset (Openverse reports a duration of 0 for MIDI files it never measured).audio.formatandpreview.mediaTypecome from one table of known filetypes:mp3,ogg,oga,opus,wav,flac,mid/midi(audio/midi) andwebm(audio/webm). Jamendo'smp31/mp32read asmp3, Wikimedia'sogxasogg. An item whose filetype is outside the table has neitheraudio.formatnor apreview, rather than a guessed media type.
Gate by intended use with refkit.evaluateUse(ref, 'commercial-product'). See @refkit/core for the full API.
