Manifest Reference
A manifest file defines how to fetch data and what parts of the response to prove, and what is required to generate a proof. Below is a complete reference of all fields in a manifest file.
Base Fields
manifestVersion
Type: string
The version of the manifest schema. Currently only version “1” is supported.
id
Type: string
A unique identifier for this manifest. Used to track and reference manifests internally.
title
Type: string
A human-readable name for what this manifest proves. Should be concise but descriptive.
description
Type: string
A longer description explaining what data this manifest proves and how it works.
prepareUrl
Type: string
(optional)
URL that requires preprocessing (like authentication) before making the main request. When specified, requires a prepare.js
file to handle the authentication flow.
Request Object
request.method
Type: "GET" | "POST" | "PUT" | "DELETE" | "PATCH"
The HTTP method to use for the request.
request.url
Type: string
The endpoint URL to fetch data from.
request.headers
Type: Record<string, string>
Required headers that will be locked and verified. Common headers like Content-Type
and Authorization
.
request.extra
Type: { headers?: Record<string, string> }
Additional headers that will be sent but not verified. Useful for obtaining certain responses.
request.body
Type: string | Record<string, any>
The request body. If an object is provided, it will be serialized to JSON.
request.vars
Type: Record<string, VarConstraint>
Response Object
response.status
Type: string
The expected HTTP status code that will be verified.
response.headers
Type: Record<string, string>
Response headers that must be present and match exactly.
response.body
Type: { json?: (string | number)[][] }
Specifies which parts of the JSON response to extract and verify. The array represents the path to the data in the response JSON.