Skip to content
SETSimple Easy Transactions
SET DocsSET Crypto API Suite and SET API referenceCurrent as of 2026-11-21 · wallet release 7d8a79fb
Browse: SET Crypto API Suite

SET Crypto API Suite · Positions and watched addresses

Note a balance mismatch

POST/v1/close/positions/{position}/note

Key scope: write · Success: 200

Records a note on a position check in state balance_mismatch: what was found and why. A mismatch with no note blocks preparing its month.

Path parameters

position stringrequired
The position check's id: cp_ followed by 32 hex characters.

Headers

Idempotency-Key string
Any unique string, so a retry runs once. See Idempotency.

Body

note stringrequired
What was found and why, 1 to 500 characters. Missing or empty answers 400 note_required.

Notes

  • SET Close is switched on per deployment; while it is off every /v1/close/* call answers 403 close_off. Check GET /v1/capabilities (features.close).
  • Needs a key with the write scope.
  • Only a check in state balance_mismatch takes a note: any other state answers 409 not_a_mismatch.
  • The note can be written only while the check's month is neither prepared nor locked: 409 period_locked after that.
  • notedBy is the key that wrote the note. A second note replaces the first until the month is prepared.
  • A mismatch with no note blocks POST /v1/close/periods/{period}/prepare (409 open_position_mismatches).
  • Emits the event close.position.noted.
  • A sandbox wallet's check is always not_applicable, so only a live wallet can have a mismatch; the example's mismatch row (provider 1250.50 USDC, chain 1249.50 USDC) was prepared for illustration.
  • This example is a recorded run of SET's own code (wallet release e9b03447) with a sandbox key; ids and times are that run's.

Errors

  • 403 close_off
  • 400 note_required
  • 404 not_found
  • 409 not_a_mismatch
  • 409 period_locked

All codes: Errors.