Chord check: identify, spell, key membership, transpose

$0.005 USDC per call · Business, finance and compliance · POST /api/v1/chord-check · Id chord-check

Names a chord from its notes, spells a chord symbol into notes, tests whether a chord is diatonic to a key, or transposes a chord symbol, using pitch-class arithmetic over a fixed table of 21 chord qualities, for agents handling lead sheets and music metadata. Rule-based and labelled: when several readings are equally valid (C E G A is C6 or Am7/C) or no quality in the table matches, it returns unknown with the candidates instead of choosing. Does NOT use harmonic context, analyse progressions, infer keys, or know quality names outside its table.

What you get

Stops an agent asserting a chord name or key the notes do not support.

Call it

Send the JSON body below to https://agents.writerslogic.com/api/v1/chord-check. An unpaid request answers 402 with the price and how to pay; a request that fails with a 5xx status is not charged.

curl -i -X POST https://agents.writerslogic.com/api/v1/chord-check \
  -H 'content-type: application/json' \
  -d '{"operation":"spell","chord":"Ebmaj7","expectNotes":["Eb","G","Bb","D"]}'

Input

FieldTypeRequiredDescription
operationstring; one of "identify", "spell", "key-membership", "transpose"yes
notesarray<string; length 0..6>; max 8 itemsnoFor identify: 2 to 8 notes.
chordstring; length 0..24noChord symbol, root A-G with optional #/b, quality suffix, optional /bass: Cmaj7, F#m7b5, Bb/D.
keyobjectnoFor key-membership.
semitonesinteger; -48..48noFor transpose: semitones up (negative down).
preferstring; one of "sharps", "flats"noAccidentals for a natural root when transposing. Default sharps; a root written with # or b keeps its kind.
expectChordstring; length 0..24noOptional claimed chord symbol to verify (identify, transpose).
expectNotesarray<string; length 0..4>; max 8 itemsnoOptional claimed notes in order, to verify (spell).

Example request body

{
  "operation": "spell",
  "chord": "Ebmaj7",
  "expectNotes": [
    "Eb",
    "G",
    "Bb",
    "D"
  ]
}

Result

The response is { "data": ..., "_provenance": ... }. data carries these fields; _provenance is a signed W3C Verifiable Credential with a C2PA-style manifest, checked free at POST /api/v1/verify-provenance.

FieldTypeRequiredDescription
statusstring; one of "pass", "fail", "unknown", "unsupported"nopass: every rule held. fail: a rule was violated (see witnesses). unknown: the input lacks the evidence to decide. unsupported: outside what this engine covers. Missing evidence is never a pass.
operationstringno
chordstring; length 0..200noNormalised chord symbol.
readingsarray<object>no
notesarray<string>noSpelled chord tones, bass first when it is not a chord tone.
pitchClassesarray<integer>noSorted pitch classes, C = 0.
diatonicbooleanno
outOfKeyarray<string>no
degreeintegernoScale degree of the chord root when it is in the scale.
scalearray<string>no
witnessesarray<object>no
versionsobjectnoEvery semantic dependency of this answer (engine, tables and their as-of dates, tokenizer, calendar, rounding profile).
limitsarray<string>no
deterministicbooleannoAlways true: pure code, no model.

Pay and connect

Available through: x402 (USDC on Base), MCP. MCP clients reach it through the creative-games-kit package.

Machine-readable