You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
DPNS: expose registration eligibility (normalized name + identity) from Rust before a preorder is paid #6234
Both example apps enable "Register" for a DPNS label when dash_sdk_dpns_check_availability reports available: true. That check (Sdk::dpns_name_state, packages/rs-sdk/src/platform/dpns_usernames/give_up.rs) reads only the awarded domain and the tombstone. It cannot tell that Platform will refuse the entry when:
the name's contest no longer accepts entries,
the contest ended in a lock,
the identity has already joined the contest (PV15: a successful join deletes the preorder but leaves no domain, so a later check of the same normalized name still says available).
Registration (register_dpns_name_with_owner_balance_and_metadata) confirms the paid preorder before it tries the domain create, so in these cases the user pays for a preorder and then gets a refusal.
Proposal
Add a proof-backed Rust query for "can this identity register this normalized name now" that covers a new entrant in an open contest plus the three refusal cases above. Expose it through rs-sdk-ffi / platform-wallet-ffi and JNI, and have SwiftExampleApp and KotlinExampleApp gate Register on it. Neither app should duplicate the contest rules.
Found in review of #6225 (KotlinExampleApp now gates Register on the existing availability check, as Swift does).
Activity