Skip to content

feat(antd-go): PrepareUploadPublic + DataMapAddress#58

Merged
Nic-dorman merged 1 commit into
mainfrom
feat/antd-go-prepare-upload-public
May 6, 2026
Merged

feat(antd-go): PrepareUploadPublic + DataMapAddress#58
Nic-dorman merged 1 commit into
mainfrom
feat/antd-go-prepare-upload-public

Conversation

@Nic-dorman
Copy link
Copy Markdown
Collaborator

@Nic-dorman Nic-dorman commented May 5, 2026

Summary

Adds the antd-go consumer for the visibility/data_map_address wire shape landed in antd 0.6.1 (#57). This is indelible's migration target for the bundled atomic external-signer public upload.

Change

  • New method PrepareUploadPublic(ctx, path) (*PrepareUploadResult, error) — POSTs visibility:"public" to /v1/upload/prepare. The daemon bundles the serialized DataMap as one extra chunk in the same PreparedUpload payment batch, so the external signer signs ONE EVM tx covering chunks + DataMap.
  • New field DataMapAddress string on FinalizeUploadResult, populated from the daemon's data_map_address response field when the upload was prepared with visibility:"public".
  • Existing PrepareUpload / FinalizeUpload signatures unchanged. Old daemons (pre-0.6.1) don't return data_map_address, so the new field is empty for callers talking to them — backward compatible.

Wire-compat

Caller Daemon Result
PrepareUploadPublic antd >= 0.6.1 true public prepare; bundled DataMap; DataMapAddress populated on finalize
PrepareUploadPublic antd < 0.6.1 daemon ignores visibility field, returns private prepare; DataMapAddress stays "" on finalize
PrepareUpload (old method) any unchanged behavior, DataMapAddress stays ""

Test plan

  • go test ./... — 4 new test cases pass alongside existing suite:
    • TestPrepareUploadPublicSendsVisibility — verifies the request body contains visibility:"public"
    • TestFinalizeUploadSurfacesDataMapAddress — verifies the new field is extracted from the response
    • TestFinalizeUploadOmitsDataMapAddressForPrivate — verifies wire-compat with daemons that don't emit the field
  • End-to-end mainnet validation against the antd 0.6.1 daemon (via the equivalent Python wire shape — same JSON requests/responses): 4 quotes paid in 1 atomic tx, finalize returned data_map_address, download_public round-tripped byte-for-byte. See feat(antd): wire visibility through /v1/upload/prepare #57 for the on-chain artifacts.

Next

  • After merge, cut antd-go/v0.6.1 tag for indelible to consume.

🤖 Generated with Claude Code

…al-signer public uploads

Mirrors the wire shape landed in antd 0.6.1 (#57):

- New method PrepareUploadPublic(ctx, path) — POSTs visibility:"public" to
  /v1/upload/prepare. The daemon bundles the serialized DataMap as one
  extra chunk in the same PreparedUpload payment batch, so the external
  signer signs ONE EVM transaction covering chunks + DataMap.
- New field DataMapAddress on FinalizeUploadResult, populated from the
  daemon's response when the upload was prepared with visibility:"public".
- Existing PrepareUpload / FinalizeUpload signatures unchanged. Old
  daemons (pre-0.6.1) don't return data_map_address, so the new field
  is empty for callers talking to those — backward compatible.

Tests verify:
- PrepareUploadPublic actually sends visibility:"public" in the request.
- FinalizeUpload surfaces data_map_address when the daemon returns it.
- FinalizeUpload leaves DataMapAddress empty for old daemons that don't
  emit the field (wire-compat).

Requires antd >= 0.6.1 to take effect; calls against older daemons
silently degrade to the private path (the visibility field is ignored
upstream and DataMapAddress stays empty).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Nic-dorman Nic-dorman force-pushed the feat/antd-go-prepare-upload-public branch from 9479369 to 26d382c Compare May 6, 2026 16:24
@Nic-dorman Nic-dorman marked this pull request as ready for review May 6, 2026 16:24
@Nic-dorman Nic-dorman merged commit 085535a into main May 6, 2026
@Nic-dorman Nic-dorman deleted the feat/antd-go-prepare-upload-public branch May 6, 2026 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant