loremfile

v0.2.3
io.github.kumarprabhashanand/loremfile Checked 3 days ago Published 12 hours ago

CC0 sample files and test fixtures: find one, get its URL and SHA-256, check a copy on disk.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

list_fixtures List loremfile.dev fixtures

One page of the published sample files, filtered by format, tag and size. Reads the published manifest over the network. Each comes with its URL and a description of what it is for. `total` counts every match and `next_offset` fetches the next page; it is null on the last.

ParameterTypeDescription
formatFormats to include, any of, e.g. ["pdf", "png"].
limitintegerFixtures per page, 50 unless set, at most 250.
max_bytesintegerOnly files of at most this size.
offsetintegerMatches to skip.
tagTags to include, any of, e.g. ["encrypted"].

describe_fixture Describe one loremfile.dev fixture

The published manifest entry for one fixture: its URL, MIME type, size, SHA-256, tags, description and measured properties. Reads the published manifest over the network. Metadata only; fetch the URL for the file.

ParameterTypeDescription
path *stringA fixture path, e.g. "pdf/minimal.pdf".

verify_file Verify a local copy of a loremfile.dev fixture

Hash a file on this machine and compare it with the published SHA-256 and size of a fixture. Reads the published manifest over the network. `status` is ok, changed or missing. The file is read only to hash it.

ParameterTypeDescription
file *stringThe local file: absolute, or relative to where the server was started.
path *stringThe fixture path, e.g. "pdf/minimal.pdf".