← Obsidian Link Checker
Your token

Obsidian Link Checker API

Checking links, finding orphan notes and unlinked mentions, the fixes and every download run free in the browser and need no API. The API is for the one metered step: send the notes nothing links to, each with up to 5 likely candidate notes and the page's measures of how they relate, and get back, as JSON, which candidates should link to each note, each with one reason from a fixed list. The page builds this input from your vault and checks every link before showing it.

Base URL: https://api.skillsafe.ai/v1/app-api. Every response is {"data": ...} or {"error": {"code", "message"}}; read error.code and error.message rather than the HTTP status alone.

The task field

This app has one task. Always send "task": "connect".

taskWhat it doesReply
connectFor each note nothing links to, chooses up to per_note of its candidates that should link to it, or skips it, each link with a reason that checks out.One JSON object

Input fields

Every field is a string; facts and limits hold JSON text. All three are required.

FieldMeaning
task"connect"
factsJSON object: orphans, up to 8, each {id, title, folder, tags, excerpt, candidates}, where each candidate is {id, title, folder, tags, excerpt, mentions_it, same_folder, shared_tags, shared_words, similarity}; orphans_total; sent.
limits{per_note, shared_words_min}: per_note is 1, 2 or 3.

The reply

job.output.output is text holding one JSON object: links, an array of {"to", "from", "why"}, and skip, an array of note ids. why is one of mentions_it, same_tag, same_folder, shared_words, same_topic. Before using it, check it as the page does: to is a note sent, from is one of that note's own candidates, no note has more than per_note links, every note is in links or skip, and each reason checks out (mentions_it: the candidate's mentions_it is true; same_tag: shared_tags is not empty; same_folder: same_folder is true; shared_words: at least shared_words_min shared words). If the balance ran low, truncated is true and the list may stop early; the page keeps the links that arrived whole.

Worked example

Input (input.json), from the page's "Biology notes" example with up to 2 links per note:

{
  "task": "connect",
  "facts": "{\"orphans\":[{\"id\":\"n1\",\"title\":\"Adenosine triphosphate\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The molecule cells use to carry energy. Made mostly in the mitochondria during cellular respiration.\",\"candidates\":[{\"id\":\"n9\",\"title\":\"Mitochondria\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Site of Cellular respiration, which releases the energy cells store as ATP.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\",\"cells\",\"cellular\",\"energy\"],\"similarity\":0.176},{\"id\":\"n4\",\"title\":\"Cellular respiration\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"Glucose and oxygen become carbon dioxide and water, and the energy released is stored as ATP. Happens in the Mitochondira. Aerobic Needs oxygen. Anaerobic...\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"cellular\",\"respiration\",\"energy\"],\"similarity\":0.093},{\"id\":\"n12\",\"title\":\"Photosynthesis\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Plants use light energy to turn carbon dioxide and water into glucose and oxygen, in the Chloroplast. leaf-diagram.png Light-dependent reactions Happen in the...\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"cellular\",\"energy\",\"respiration\"],\"similarity\":0.033},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"cells\",\"mitochondria\"],\"similarity\":0.04},{\"id\":\"n6\",\"title\":\"Diffusion\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The net movement of particles from where they are more concentrated to where they are less concentrated. Osmosis is the diffusion of water across a membrane....\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\"],\"similarity\":0.019}]},{\"id\":\"n6\",\"title\":\"Diffusion\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The net movement of particles from where they are more concentrated to where they are less concentrated. Osmosis is the diffusion of water across a membrane. Oxygen reaches the mitochondria by diffusion.\",\"candidates\":[{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"diffusion\",\"membrane\",\"osmosis\",\"water\"],\"similarity\":0.244},{\"id\":\"n11\",\"title\":\"Osmosis\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"The movement of water across a partially permeable membrane, from a dilute solution to a more concentrated one. Water movement Plant cells take in water and...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"movement\",\"concentrated\",\"osmosis\",\"water\"],\"similarity\":0.306},{\"id\":\"n9\",\"title\":\"Mitochondria\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Site of Cellular respiration, which releases the energy cells store as ATP.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\"],\"similarity\":0.085},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"membrane\",\"mitochondria\",\"osmosis\"],\"similarity\":0.074},{\"id\":\"n4\",\"title\":\"Cellular respiration\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"Glucose and oxygen become carbon dioxide and water, and the energy released is stored as ATP. Happens in the Mitochondira. Aerobic Needs oxygen. Anaerobic...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"oxygen\",\"less\",\"water\"],\"similarity\":0.09}]},{\"id\":\"n7\",\"title\":\"DNA\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"A double helix that carries the genes. Kept in the nucleus. Genes are instructions for proteins, including enzymes.\",\"candidates\":[{\"id\":\"n10\",\"title\":\"Nucleus\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Holds the cell's DNA and controls what the cell makes.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"dna\",\"nucleus\"],\"similarity\":0.26},{\"id\":\"n8\",\"title\":\"Enzymes\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Proteins that speed up reactions without being used up. Each one fits its substrate, so temperature and pH change how fast it works.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"enzymes\",\"proteins\"],\"similarity\":0.155},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"nucleus\"],\"similarity\":0.023}]},{\"id\":\"n8\",\"title\":\"Enzymes\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Proteins that speed up reactions without being used up. Each one fits its substrate, so temperature and pH change how fast it works.\",\"candidates\":[{\"id\":\"n7\",\"title\":\"DNA\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"A double helix that carries the genes. Kept in the nucleus. Genes are instructions for proteins, including enzymes.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"enzymes\",\"proteins\"],\"similarity\":0.155},{\"id\":\"n12\",\"title\":\"Photosynthesis\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Plants use light energy to turn carbon dioxide and water into glucose and oxygen, in the Chloroplast. leaf-diagram.png Light-dependent reactions Happen in the...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"reactions\"],\"similarity\":0.054},{\"id\":\"n1\",\"title\":\"Adenosine triphosphate\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The molecule cells use to carry energy. Made mostly in the mitochondria during cellular respiration.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0},{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0}]},{\"id\":\"n13\",\"title\":\"Exam prep\",\"folder\":\"\",\"tags\":[],\"excerpt\":\"Revise Photosynthesis Revise Cell Practice questions on Osmosis\",\"candidates\":[{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\",\"osmosis\"],\"similarity\":0.072},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\",\"osmosis\"],\"similarity\":0.056},{\"id\":\"n5\",\"title\":\"Chloroplast\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Where Photosynthesis happens. It contains chlorophyll, which absorbs light. chloroplast.png See Photosynthesis.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"photosynthesis\"],\"similarity\":0.052},{\"id\":\"n10\",\"title\":\"Nucleus\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Holds the cell's DNA and controls what the cell makes.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\"],\"similarity\":0.044}]}],\"orphans_total\":5,\"sent\":5}",
  "limits": "{\"per_note\":2,\"shared_words_min\":2}"
}

Reply:

{"links":[{"to":"n1","from":"n9","why":"mentions_it"},{"to":"n1","from":"n4","why":"mentions_it"},{"to":"n6","from":"n2","why":"mentions_it"},{"to":"n6","from":"n11","why":"same_folder"},{"to":"n7","from":"n10","why":"mentions_it"},{"to":"n7","from":"n8","why":"same_folder"},{"to":"n8","from":"n7","why":"mentions_it"}],"skip":["n13"]}

Errors

HTTPWhat to do
401The token is missing, expired or a guest token on a run. Get a personal token on the token page.
402The balance is below what the run reserves. Top up at skillsafe.ai/account/billing.
400The body is not a JSON object of the fields above, or a required field is missing or empty.
429Wait and retry with the same Idempotency-Key.

Step 1 — a tiny client helper

One function that sends JSON and unwraps the {data, error} envelope.

BASE="https://api.skillsafe.ai/v1/app-api"
TOKEN="paste-your-token-here"   # from https://obsidian-link-checker.skillsafe.ai/tokens.html
api() { # api METHOD PATH [JSON-BODY]
  curl -s -X "$1" "$BASE$2" -H "Content-Type: application/json" \
    ${TOKEN:+-H "Authorization: Bearer $TOKEN"} ${3:+--data "$3"}
}

Step 2 — a token

A guest token is enough for /me and /estimate. A run is metered, so it needs your personal token: sign in on the token page and copy it.

# a guest token (enough for /me and /estimate); a run needs your personal token from /tokens.html
TOKEN=$(curl -s -X POST "$BASE/guest" -H "Content-Type: application/json" -d '{"slug":"obsidian-link-checker"}' | jq -r '.data.token')

Step 3 — who am I, and my balance

subject_type is guest or user; credits is the balance (1 credit = $0.0001).

api GET /me | jq '.data | {subject_type, credits}' 

Step 4 — price a run for free

/estimate charges nothing and starts no job. hold_credits is the amount reserved while a run is in flight, not the price; the run is charged what it uses.

# input.json: the run input object - {"task": "connect", "facts": "{\"orphans\":[{\"id\":\"n1\",\"title\":\"Adenosine triphosphate\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The molecule cells use to carry energy. Made mostly in the mitochondria during cellular respiration.\",\"candidates\":[{\"id\":\"n9\",\"title\":\"Mitochondria\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Site of Cellular respiration, which releases the energy cells store as ATP.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\",\"cells\",\"cellular\",\"energy\"],\"similarity\":0.176},{\"id\":\"n4\",\"title\":\"Cellular respiration\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"Glucose and oxygen become carbon dioxide and water, and the energy released is stored as ATP. Happens in the Mitochondira. Aerobic Needs oxygen. Anaerobic...\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"cellular\",\"respiration\",\"energy\"],\"similarity\":0.093},{\"id\":\"n12\",\"title\":\"Photosynthesis\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Plants use light energy to turn carbon dioxide and water into glucose and oxygen, in the Chloroplast. leaf-diagram.png Light-dependent reactions Happen in the...\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"cellular\",\"energy\",\"respiration\"],\"similarity\":0.033},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"cells\",\"mitochondria\"],\"similarity\":0.04},{\"id\":\"n6\",\"title\":\"Diffusion\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The net movement of particles from where they are more concentrated to where they are less concentrated. Osmosis is the diffusion of water across a membrane....\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\"],\"similarity\":0.019}]},{\"id\":\"n6\",\"title\":\"Diffusion\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The net movement of particles from where they are more concentrated to where they are less concentrated. Osmosis is the diffusion of water across a membrane. Oxygen reaches the mitochondria by diffusion.\",\"candidates\":[{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"diffusion\",\"membrane\",\"osmosis\",\"water\"],\"similarity\":0.244},{\"id\":\"n11\",\"title\":\"Osmosis\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"The movement of water across a partially permeable membrane, from a dilute solution to a more concentrated one. Water movement Plant cells take in water and...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"movement\",\"concentrated\",\"osmosis\",\"water\"],\"similarity\":0.306},{\"id\":\"n9\",\"title\":\"Mitochondria\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Site of Cellular respiration, which releases the energy cells store as ATP.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"mitochondria\"],\"similarity\":0.085},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"membrane\",\"mitochondria\",\"osmosis\"],\"similarity\":0.074},{\"id\":\"n4\",\"title\":\"Cellular respiration\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"Glucose and oxygen become carbon dioxide and water, and the energy released is stored as ATP. Happens in the Mitochondira. Aerobic Needs oxygen. Anaerobic...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"oxygen\",\"less\",\"water\"],\"similarity\":0.09}]},{\"id\":\"n7\",\"title\":\"DNA\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"A double helix that carries the genes. Kept in the nucleus. Genes are instructions for proteins, including enzymes.\",\"candidates\":[{\"id\":\"n10\",\"title\":\"Nucleus\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Holds the cell's DNA and controls what the cell makes.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"dna\",\"nucleus\"],\"similarity\":0.26},{\"id\":\"n8\",\"title\":\"Enzymes\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Proteins that speed up reactions without being used up. Each one fits its substrate, so temperature and pH change how fast it works.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"enzymes\",\"proteins\"],\"similarity\":0.155},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"nucleus\"],\"similarity\":0.023}]},{\"id\":\"n8\",\"title\":\"Enzymes\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Proteins that speed up reactions without being used up. Each one fits its substrate, so temperature and pH change how fast it works.\",\"candidates\":[{\"id\":\"n7\",\"title\":\"DNA\",\"folder\":\"Biology\",\"tags\":[],\"excerpt\":\"A double helix that carries the genes. Kept in the nucleus. Genes are instructions for proteins, including enzymes.\",\"mentions_it\":true,\"same_folder\":true,\"shared_tags\":[],\"shared_words\":[\"enzymes\",\"proteins\"],\"similarity\":0.155},{\"id\":\"n12\",\"title\":\"Photosynthesis\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Plants use light energy to turn carbon dioxide and water into glucose and oxygen, in the Chloroplast. leaf-diagram.png Light-dependent reactions Happen in the...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[\"reactions\"],\"similarity\":0.054},{\"id\":\"n1\",\"title\":\"Adenosine triphosphate\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The molecule cells use to carry energy. Made mostly in the mitochondria during cellular respiration.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0},{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":true,\"shared_tags\":[\"biology\"],\"shared_words\":[],\"similarity\":0}]},{\"id\":\"n13\",\"title\":\"Exam prep\",\"folder\":\"\",\"tags\":[],\"excerpt\":\"Revise Photosynthesis Revise Cell Practice questions on Osmosis\",\"candidates\":[{\"id\":\"n2\",\"title\":\"Cell membrane\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"A thin layer around every cell. Water crosses it by osmosis and small molecules by diffusion.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\",\"osmosis\"],\"similarity\":0.072},{\"id\":\"n3\",\"title\":\"Cell\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"The basic unit of life. Plant cells have a Cell wall, and many have chloroplasts; animal cells have neither. Organelles Nucleus Mitochondria Chloroplast...\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\",\"osmosis\"],\"similarity\":0.056},{\"id\":\"n5\",\"title\":\"Chloroplast\",\"folder\":\"Biology\",\"tags\":[\"biology\",\"plants\"],\"excerpt\":\"Where Photosynthesis happens. It contains chlorophyll, which absorbs light. chloroplast.png See Photosynthesis.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"photosynthesis\"],\"similarity\":0.052},{\"id\":\"n10\",\"title\":\"Nucleus\",\"folder\":\"Biology\",\"tags\":[\"biology\"],\"excerpt\":\"Holds the cell's DNA and controls what the cell makes.\",\"mentions_it\":false,\"same_folder\":false,\"shared_tags\":[],\"shared_words\":[\"cell\"],\"similarity\":0.044}]}],\"orphans_total\":5,\"sent\":5}", "limits": "{\"per_note\":2,\"shared_words_min\":2}"}
api POST /estimate "$(cat input.json)" | jq '.data | {hold_credits, min_credits, model, model_alias, markup_bps, warnings}' 

Step 5 — run it and wait for the job

Send an Idempotency-Key derived from the input: a retry with the same key is never billed twice.

KEY="obsidian-link-checker:connect:$(shasum -a 256 input.json | cut -c1-16):a1"
JOB=$(curl -s -X POST "$BASE/run" -H "Content-Type: application/json" -H "Authorization: Bearer $TOKEN" \
  -H "Idempotency-Key: $KEY" --data @input.json | jq -r '.data.job_id')
while :; do
  J=$(api GET "/jobs/$JOB"); S=$(echo "$J" | jq -r '.data.status')
  case "$S" in succeeded|failed|cancelled) break;; esac; sleep 2
done
echo "$J" | jq -r '.data.output.output' > reply.json   # one JSON object: links and skip
echo "$J" | jq '.data | {charged_credits, truncated}' 

Step 6 — or stream it

/run-stream sends Server-Sent Events while the job runs and the finished job at the end.

# Server-Sent Events: tick/delta events while the job runs, then a final event with the job
curl -N -s -X POST "$BASE/run-stream" -H "Content-Type: application/json" -H "Authorization: Bearer $TOKEN" \
  -H "Idempotency-Key: obsidian-link-checker:connect:$(shasum -a 256 input.json | cut -c1-16):a1" --data @input.json