# \#best-practices

**URL:** https://forum.midnight.network/tag/best-practices/5.md

[Latest](https://forum.midnight.network/latest.md) · [Categories](https://forum.midnight.network/categories.md) · [Tags](https://forum.midnight.network/tags.md)

---

## [\[RFC\] MIP-?: Midnight Agent Identity Standard (MAIS)](https://forum.midnight.network/t/rfc-mip-midnight-agent-identity-standard-mais/1231)

<div class="topic-metadata">

**Author:** [@mzf11125](https://forum.midnight.network/u/mzf11125)\
**Replies:** 3\
**Last updated:** [October 13, 2026, 1:35pm UTC](https://forum.midnight.network/t/rfc-mip-midnight-agent-identity-standard-mais/1231 "2026-10-13T13:35:36Z")

</div>

Category: Standards, Midnight Improvement Proposal Status: Draft, looking for community feedback before formal submission TL;DR AI agents are arriving on Midnight. Midnight City already runs Gemini agents. AlphaTON is…

---

## [ZKP compliance for 42 CFR Part 2 — substance use treatment privacy](https://forum.midnight.network/t/zkp-compliance-for-42-cfr-part-2-substance-use-treatment-privacy/1218)

<div class="topic-metadata">

**Author:** [@DR.Ecovery](https://forum.midnight.network/u/DR.Ecovery)\
**Replies:** 7\
**Last updated:** [May 31, 2026, 2:40pm UTC](https://forum.midnight.network/t/zkp-compliance-for-42-cfr-part-2-substance-use-treatment-privacy/1218 "2026-05-31T14:40:35Z")

</div>

I’m building a check-in app for a drug recovery drop-in center using Midnight’s ZKP technology. 42 CFR Part 2 is a federal law that protects substance use treatment records — even stricter than HIPAA. It means you can’t…

---

## [Major Update: Midnight Agent Skills v2.0 – Preprod Migration & MCP Integration](https://forum.midnight.network/t/major-update-midnight-agent-skills-v2-0-preprod-migration-mcp-integration/1186)

<div class="topic-metadata">

**Author:** [@mzf11125](https://forum.midnight.network/u/mzf11125)\
**Replies:** 3\
**Last updated:** [April 30, 2026, 2:57am UTC](https://forum.midnight.network/t/major-update-midnight-agent-skills-v2-0-preprod-migration-mcp-integration/1186 "2026-04-30T02:57:19Z")

</div>

Hello again Midnight community, Following up on my initial post about Midnight Agent Skills ( GitHub - mzf11125/midnight\_agent\_skills · GitHub ), I want to share a massive update (v2.0.1) we just rolled out to keep AI a…

---

## [Midnight Agent Skills v2.0.3 – Full Community Knowledge Base (27 Aliit Articles)](https://forum.midnight.network/t/midnight-agent-skills-v2-0-3-full-community-knowledge-base-27-aliit-articles/1189)

<div class="topic-metadata">

**Author:** [@mzf11125](https://forum.midnight.network/u/mzf11125)\
**Replies:** 0\
**Last updated:** [April 29, 2026, 4:55pm UTC](https://forum.midnight.network/t/midnight-agent-skills-v2-0-3-full-community-knowledge-base-27-aliit-articles/1189 "2026-04-29T16:55:56Z")

</div>

Following up on my previous posts about Midnight Agent Skills ( GitHub - mzf11125/midnight\_agent\_skills: 4 modular agent skills for building on Midnight Network's zero-knowledge blockchain · GitHub ), I’ve just shipped v…

---

## [MIDNIGHT. \[ BEYOND MAINNET\]](https://forum.midnight.network/t/midnight-beyond-mainnet/1134)

<div class="topic-metadata">

**Author:** [@yinkabir](https://forum.midnight.network/u/yinkabir)\
**Replies:** 0\
**Last updated:** [April 5, 2026, 5:21pm UTC](https://forum.midnight.network/t/midnight-beyond-mainnet/1134 "2026-04-05T17:21:34Z")

</div>

Midnight isn’t just launching a blockchain; it’s launching a “Compliance-First Stealth Layer” for the global economy. To beat the competition post-Mainnet, Midnight is playing a different game: The “Clean Privacy” …

---

## [Midnight Compact Agent Skill -- Compiler-Validated Reference for AI-Assisted Development](https://forum.midnight.network/t/midnight-compact-agent-skill-compiler-validated-reference-for-ai-assisted-development/1083)

<div class="topic-metadata">

**Author:** [@Zaphod](https://forum.midnight.network/u/Zaphod)\
**Replies:** 0\
**Last updated:** [March 14, 2026, 10:54am UTC](https://forum.midnight.network/t/midnight-compact-agent-skill-compiler-validated-reference-for-ai-assisted-development/1083 "2026-03-14T10:54:12Z")

</div>

Midnight Compact Agent Skill – Compiler-Validated Reference for AI-Assisted Development What it is An open-source Agent Skill that teaches AI coding assistants how to write Compact smart contracts for Midnight. It work…

---

## [Standardizing AI-Assisted Development on Midnight](https://forum.midnight.network/t/standardizing-ai-assisted-development-on-midnight/1038)

<div class="topic-metadata">

**Author:** [@mzf11125](https://forum.midnight.network/u/mzf11125)\
**Replies:** 1\
**Last updated:** [March 5, 2026, 1:09am UTC](https://forum.midnight.network/t/standardizing-ai-assisted-development-on-midnight/1038 "2026-03-05T01:09:44Z")

</div>

Hello Midnight community, I’ve created Midnight Agent Skills, an open-source collection of structured skill modules designed to help AI coding assistants reliably support Midnight development: https://github.com/mzf111…

---

## [Wallet syncing 50% for 3 days now](https://forum.midnight.network/t/wallet-syncing-50-for-3-days-now/742)

<div class="topic-metadata">

**Author:** [@iano](https://forum.midnight.network/u/iano)\
**Replies:** 6\
**Last updated:** [February 5, 2026, 3:45pm UTC](https://forum.midnight.network/t/wallet-syncing-50-for-3-days-now/742 "2026-02-05T15:45:56Z")

</div>

GM team, my wallet has been syncing at 50% for the past half a week. It also resets itself and this forces me to enter a seed phrase everytime I intend to use it. Kindly advise.

---

## [Wallet entropy using bip39 - derive seed and build wallet using nodejs](https://forum.midnight.network/t/wallet-entropy-using-bip39-derive-seed-and-build-wallet-using-nodejs/325)

<div class="topic-metadata">

**Author:** [@fosgate29](https://forum.midnight.network/u/fosgate29)\
**Replies:** 9\
**Last updated:** [February 4, 2026, 1:08am UTC](https://forum.midnight.network/t/wallet-entropy-using-bip39-derive-seed-and-build-wallet-using-nodejs/325 "2026-02-04T01:08:19Z")

</div>

I created a new wallet using Lace wallet. And I got 24 words. Now I would like to know how I can derive the seed from 24 words in nodejs. I was using bip39 and was able to build my wallet. Here is my code: const entrop…

---

## [Midnight Escrow prototype](https://forum.midnight.network/t/midnight-escrow-prototype/798)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 4\
**Last updated:** [January 27, 2026, 7:15pm UTC](https://forum.midnight.network/t/midnight-escrow-prototype/798 "2026-01-27T19:15:14Z")

</div>

Hey guys! Just shipped an escrow prototype on Midnight — simple flow, friendly UI, and full privacy!! :link: GitHub: https://github.com/MeshJS/midnight-escrow-system

---

## [Testing smart contract with time manipulation](https://forum.midnight.network/t/testing-smart-contract-with-time-manipulation/931)

<div class="topic-metadata">

**Author:** [@techmartins](https://forum.midnight.network/u/techmartins)\
**Replies:** 1\
**Last updated:** [January 8, 2026, 12:02am UTC](https://forum.midnight.network/t/testing-smart-contract-with-time-manipulation/931 "2026-01-08T00:02:26Z")

</div>

I have a contract logic that executes only after a specific time (defined during contract deployment). The contract logic relies on checking the current time via witness (using Date javascript method). Testing the contr…

---

## [Addressing the issue of $Night receiving addresses having exposed seed phrases.](https://forum.midnight.network/t/addressing-the-issue-of-night-receiving-addresses-having-exposed-seed-phrases/908)

<div class="topic-metadata">

**Author:** [@Hana](https://forum.midnight.network/u/Hana)\
**Replies:** 0\
**Last updated:** [December 31, 2025, 3:49am UTC](https://forum.midnight.network/t/addressing-the-issue-of-night-receiving-addresses-having-exposed-seed-phrases/908 "2025-12-31T03:49:59Z")

</div>

Hi everyone, I’d like to ask if, in the event that someone else knows the seed phase of my $Night receiving address and I can prove I’m the owner of that seed phrase, is there any mechanism to register a change of $Night…

---

## [Compact-lsp – Language Server Protocol Implementation for Compact](https://forum.midnight.network/t/compact-lsp-language-server-protocol-implementation-for-compact/842)

<div class="topic-metadata">

**Author:** [@speres](https://forum.midnight.network/u/speres)\
**Replies:** 0\
**Last updated:** [December 17, 2025, 4:10am UTC](https://forum.midnight.network/t/compact-lsp-language-server-protocol-implementation-for-compact/842 "2025-12-17T04:10:50Z")

</div>

compact-lsp is a Language Server Protocol (LSP) implementation for the Compact smart contract language, providing IDE features for editors that support LSP. :warning: Note: This is an experimental project developed in …

---

## [Request for Clearer Guidance for New Users: Tools, Platforms, and Engagement Pathways](https://forum.midnight.network/t/request-for-clearer-guidance-for-new-users-tools-platforms-and-engagement-pathways/805)

<div class="topic-metadata">

**Author:** [@BaudouinMuvunga](https://forum.midnight.network/u/BaudouinMuvunga)\
**Replies:** 3\
**Last updated:** [December 14, 2025, 4:34pm UTC](https://forum.midnight.network/t/request-for-clearer-guidance-for-new-users-tools-platforms-and-engagement-pathways/805 "2025-12-14T16:34:54Z")

</div>

1. Introduction As an ambassador in the first cohort of the Midnight program, I am honored to contribute to a global community dedicated to privacy-preserving technology, secure digital innovation, and meaningful engage…

---

## [Midnight Toolings by Mesh](https://forum.midnight.network/t/midnight-toolings-by-mesh/649)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 4\
**Last updated:** [November 28, 2025, 9:18pm UTC](https://forum.midnight.network/t/midnight-toolings-by-mesh/649 "2025-11-28T21:18:46Z")

</div>

Calling all Midnight builders, here’s what we’ve built for you (and we’ll keep updating :slight\_smile: ). :toolbox: Tooling: Quick Starter Midnight Setup Contracts Wizard Proof Server Tokenless Escrow System Validator…

---

## [Fully Homomorphic Encryption (FHE) for Midnight: A Complete Guide for Builders and the Community](https://forum.midnight.network/t/fully-homomorphic-encryption-fhe-for-midnight-a-complete-guide-for-builders-and-the-community/681)

<div class="topic-metadata">

**Author:** [@BikramBiswas](https://forum.midnight.network/u/BikramBiswas)\
**Replies:** 6\
**Last updated:** [November 27, 2025, 4:26am UTC](https://forum.midnight.network/t/fully-homomorphic-encryption-fhe-for-midnight-a-complete-guide-for-builders-and-the-community/681 "2025-11-27T04:26:52Z")

</div>

FHE (Fully Homomorphic Encryption) lets Midnight smart contracts do math on encrypted data without ever decrypting it. This is the missing piece for true privacy. Currently possible but slow. With the right investment, M…

---

## [Multi-chain Project Idea - Feedback Wanted](https://forum.midnight.network/t/multi-chain-project-idea-feedback-wanted/572)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 7\
**Last updated:** [November 20, 2025, 9:05pm UTC](https://forum.midnight.network/t/multi-chain-project-idea-feedback-wanted/572 "2025-11-20T21:05:03Z")

</div>

I’m exploring a multi-chain project bridging EVM chains with Midnight, combining EVM interoperability with Midnight’s privacy and zkP features. I’d love to hear if this is something you’d be interested in, would build, …

---

## [Docker image for Midnight Proof Server failing for missing zk params](https://forum.midnight.network/t/docker-image-for-midnight-proof-server-failing-for-missing-zk-params/625)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 0\
**Last updated:** [November 17, 2025, 11:24am UTC](https://forum.midnight.network/t/docker-image-for-midnight-proof-server-failing-for-missing-zk-params/625 "2025-11-17T11:24:48Z")

</div>

Hi everyone! MeshJS brings you a solution to the zk parameter issues in Midnight. You don’t need to download anything else, just use the Docker image we’ve already built for you: :high\_voltage: Midnight Proof Server fai…

---

## [Nomenclature for contracts and libraries](https://forum.midnight.network/t/nomenclature-for-contracts-and-libraries/533)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 2\
**Last updated:** [November 4, 2025, 6:27pm UTC](https://forum.midnight.network/t/nomenclature-for-contracts-and-libraries/533 "2025-11-04T18:27:53Z")

</div>

hi guys! I have a question. I have always used/seen kebab-case naming conventions in Midnight for contracts, but for libraries it is PascalCase. Does anyone know if this is correct?

---

## [Midnight Contracts Wizard](https://forum.midnight.network/t/midnight-contracts-wizard/569)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 0\
**Last updated:** [October 28, 2025, 5:16pm UTC](https://forum.midnight.network/t/midnight-contracts-wizard/569 "2025-10-28T17:16:37Z")

</div>

Hey guys!! :star: Just released @meshsdk/midnight-contracts-wizard! A CLI to use Compact contracts, already created, compiled and documented, ready to build for Midnight Network: Lending & Borrowing. Oracle. Staking. …

---

## [Mesh - Midnight package @meshsdk/midnight-setup](https://forum.midnight.network/t/mesh-midnight-package-meshsdk-midnight-setup/503)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 8\
**Last updated:** [October 19, 2025, 12:57am UTC](https://forum.midnight.network/t/mesh-midnight-package-meshsdk-midnight-setup/503 "2025-10-19T00:57:41Z")

</div>

hey guys! with Mesh, we have created an npm package for Midnight that performs a complete setup between infrastructure, contracts, API, and frontend. Developers can easily deploy, join contracts, and read data from their…

---

## [Strategies for masking asset owners in contracts](https://forum.midnight.network/t/strategies-for-masking-asset-owners-in-contracts/499)

<div class="topic-metadata">

**Author:** [@bochaco](https://forum.midnight.network/u/bochaco)\
**Replies:** 2\
**Last updated:** [October 12, 2025, 8:49pm UTC](https://forum.midnight.network/t/strategies-for-masking-asset-owners-in-contracts/499 "2025-10-12T20:49:03Z")

</div>

I thought I could present here how I was going about hiding users identity in the Compact contract when storing data associated/owned by them, in an attempt to not only share it here for other devs., but also to get some…

---

## [Midnight-Live-View: Now Tracking Your Validator’s Historic Block Data](https://forum.midnight.network/t/midnight-live-view-now-tracking-your-validator-s-historic-block-data/312)

<div class="topic-metadata">

**Author:** [@lucifer](https://forum.midnight.network/u/lucifer)\
**Replies:** 2\
**Last updated:** [October 1, 2025, 2:20pm UTC](https://forum.midnight.network/t/midnight-live-view-now-tracking-your-validator-s-historic-block-data/312 "2025-10-01T14:20:25Z")

</div>

Introduction: We’re excited to unveil enhancements to Midnight-Live-View (0.2.1), a lightweight monitoring tool designed to keep Midnight validator operators in the loop, seamlessly. What’s New: Persistent Block …

---

## [NFT Standards for Midnight](https://forum.midnight.network/t/nft-standards-for-midnight/74)

<div class="topic-metadata">

**Author:** [@Johnny5i](https://forum.midnight.network/u/Johnny5i)\
**Replies:** 3\
**Last updated:** [September 30, 2025, 11:16am UTC](https://forum.midnight.network/t/nft-standards-for-midnight/74 "2025-09-30T11:16:20Z")

</div>

NMKR is providing the community with a repo for collaboration on the standards for NFTs on Midnight. This, I think, is particularly useful for privacy-preserving Digital Identity NFTs and protocol level wallets. Please v…

---

## [Issue with setting up Midnight Live View in the Preview Testnet](https://forum.midnight.network/t/issue-with-setting-up-midnight-live-view-in-the-preview-testnet/230)

<div class="topic-metadata">

**Author:** [@andreassosilo](https://forum.midnight.network/u/andreassosilo)\
**Replies:** 0\
**Last updated:** [August 8, 2025, 7:28pm UTC](https://forum.midnight.network/t/issue-with-setting-up-midnight-live-view-in-the-preview-testnet/230 "2025-08-08T19:28:25Z")

</div>

Hi everyone, I would like to ask for help regarding issue during setup my “Midnight Live View” for my Midnight Validator / Block Producer in the Preview testnet. GitHub repo: GitHub - Midnight-Scripts/Midnight-Live-View…

---

## [Error: failed to decode for built-in type EmbeddedFr after successful typecheck](https://forum.midnight.network/t/error-failed-to-decode-for-built-in-type-embeddedfr-after-successful-typecheck/124)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 2\
**Last updated:** [August 1, 2025, 11:02am UTC](https://forum.midnight.network/t/error-failed-to-decode-for-built-in-type-embeddedfr-after-successful-typecheck/124 "2025-08-01T11:02:22Z")

</div>

hey @lolocoding / @claude\_barde based on my research and the community’s feedback, this usually happens when the input value is out of range, and it doesn’t reduce correctly. I tested this by trying to declare the Field …

---

## [Error in response: Proving(public parameters for k=16 not found in cache)](https://forum.midnight.network/t/error-in-response-proving-public-parameters-for-k-16-not-found-in-cache/53)

<div class="topic-metadata">

**Author:** [@luislucena](https://forum.midnight.network/u/luislucena)\
**Replies:** 5\
**Last updated:** [July 22, 2025, 4:36pm UTC](https://forum.midnight.network/t/error-in-response-proving-public-parameters-for-k-16-not-found-in-cache/53 "2025-07-22T16:36:40Z")

</div>

This is a common error I have faced and the current way to solve it was through this: Download the fetch-zk-params.sh script curl -O https://raw.githubusercontent.com/bricktowers/midnight-proof-server/main/fetch-zk-para…

---

## [Are there mutable variables in compact? Is there a workaround for this?](https://forum.midnight.network/t/are-there-mutable-variables-in-compact-is-there-a-workaround-for-this/23)

<div class="topic-metadata">

**Author:** [@SamanthaHolstine](https://forum.midnight.network/u/SamanthaHolstine)\
**Replies:** 1\
**Last updated:** [May 12, 2025, 7:15pm UTC](https://forum.midnight.network/t/are-there-mutable-variables-in-compact-is-there-a-workaround-for-this/23 "2025-05-12T19:15:29Z")

</div>

I am confused about mutable variables: I need a way to share a temporary variable within a function (not a public ledger state) between if/ else blocks. Is there currently a workaround for this? Or, are there mutable va…

---

## [Is there a helper function in the Midnight JS library to replicate Compact's builtin pad() function?](https://forum.midnight.network/t/is-there-a-helper-function-in-the-midnight-js-library-to-replicate-compacts-builtin-pad-function/20)

<div class="topic-metadata">

**Author:** [@SamanthaHolstine](https://forum.midnight.network/u/SamanthaHolstine)\
**Replies:** 1\
**Last updated:** [May 12, 2025, 7:11pm UTC](https://forum.midnight.network/t/is-there-a-helper-function-in-the-midnight-js-library-to-replicate-compacts-builtin-pad-function/20 "2025-05-12T19:11:20Z")

</div>

I’m trying to use the tokenType() function in compact to calculate the TokenType of a new coin. Is there a helper function I can use in the Midnight JS library to replicate Compact’s built in pad() function? I’m struggl…
