Overview
submit_document() in lib.rs validates the hash format but then unconditionally returns 400 with the message "submit endpoint not yet implemented" (see the comment: "Endpoint behavior not yet implemented; preserve previous BAD_REQUEST semantics."). The handler doesn't even take State<AppState>, so it has no access to the Stellar client, cache, or metrics.
File
contract/src/lib.rs (submit_document)
Acceptance Criteria
Overview
submit_document()inlib.rsvalidates the hash format but then unconditionally returns400with the message "submit endpoint not yet implemented" (see the comment: "Endpoint behavior not yet implemented; preserve previous BAD_REQUEST semantics."). The handler doesn't even takeState<AppState>, so it has no access to the Stellar client, cache, or metrics.File
contract/src/lib.rs(submit_document)Acceptance Criteria
State<AppState>tosubmit_document's signaturedocument_hashto Stellar (reuse/extendStellarClient, similar toanchor_transfer's intended behavior once CT-35 lands), returningtransaction_idandanchored_aton successverify_documentdoesmetrics.increment_request_count()/increment_error_count()appropriately200/201withSubmitResponse{ success: true, transaction_id, anchored_at, error: None }on success, and a meaningful error body (not justBAD_REQUEST) on real failure