Skip to main content
Glama
OpenZeppelin

OpenZeppelin Contracts MCP Server

Official
by OpenZeppelin

stellar-non-fungible

Generate custom non-fungible token contracts compliant with SEP-50 standards using OpenZeppelin libraries. Configure features like burnability, enumerability, minting, and access control. Returns source code in Markdown format without writing to disk.

Instructions

Make a non-fungible token per the Non-Fungible Token Standard, compatible with SEP-50, similar to ERC-721.

Returns the source code of the generated contract, formatted in a Markdown code block. Does not write to disk.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
accessNoThe type of access control to provision. Ownable is a simple mechanism with a single account authorized for all privileged actions. Roles is a flexible mechanism with a separate role for each privileged action. A role can have many authorized accounts.
burnableNoWhether token holders will be able to destroy their tokens
consecutiveNoTo batch mint NFTs instead of minting them individually (sequential minting is mandatory).
enumerableNoWhether the NFTs are enumerable (can be iterated over).
infoNoMetadata about the contract and author
mintableNoWhether privileged accounts will be able to create more supply or emit more tokens
nameYesThe name of the contract
pausableNoWhether privileged accounts will be able to pause specifically marked functionality. Useful for emergency response.
sequentialNoWhether the IDs of the minted NFTs will be sequential.
symbolYesThe short symbol for the token
upgradeableNoWhether the contract can be upgraded.

Implementation Reference

  • The async handler function that implements the core logic of the 'stellar-non-fungible' tool: it destructures input parameters, constructs NonFungibleOptions, generates Rust code using nonFungible.print(opts) wrapped in safePrintRustCodeBlock, and returns it as text content.
    async ({ name, symbol, tokenUri, burnable, enumerable, consecutive, pausable, mintable, sequential, upgradeable, info, }) => { const opts: NonFungibleOptions = { name, symbol, tokenUri, burnable, enumerable, consecutive, pausable, mintable, sequential, upgradeable, info, }; return { content: [ { type: 'text', text: safePrintRustCodeBlock(() => nonFungible.print(opts)), }, ], }; },
  • Zod schema defining the input shape for the 'stellar-non-fungible' tool, including required name/symbol and optional flags like burnable, mintable, etc.
    export const nonFungibleSchema = { name: z.string().describe(commonDescriptions.name), symbol: z.string().describe(commonDescriptions.symbol), tokenUri: z.string().optional().describe(stellarNonFungibleDescriptions.tokenUri), burnable: z.boolean().optional().describe(commonDescriptions.burnable), enumerable: z.boolean().optional().describe(stellarNonFungibleDescriptions.enumerable), consecutive: z.boolean().optional().describe(stellarNonFungibleDescriptions.consecutive), pausable: z.boolean().optional().describe(commonDescriptions.pausable), mintable: z.boolean().optional().describe(commonDescriptions.mintable), sequential: z.boolean().optional().describe(stellarNonFungibleDescriptions.sequential), ...commonSchema, } as const satisfies z.ZodRawShape;
  • Direct registration of the 'stellar-non-fungible' tool using server.tool(), including name, detailed prompt, schema reference, and inline handler. This function is called from higher-level aggregators.
    export function registerStellarNonFungible(server: McpServer): RegisteredTool { return server.tool( 'stellar-non-fungible', makeDetailedPrompt(stellarPrompts.NonFungible), nonFungibleSchema, async ({ name, symbol, tokenUri, burnable, enumerable, consecutive, pausable, mintable, sequential, upgradeable, info, }) => { const opts: NonFungibleOptions = { name, symbol, tokenUri, burnable, enumerable, consecutive, pausable, mintable, sequential, upgradeable, info, }; return { content: [ { type: 'text', text: safePrintRustCodeBlock(() => nonFungible.print(opts)), }, ], }; }, ); }
  • Aggregator function that registers all Stellar tools (including non-fungible via registerStellarNonFungible) by dynamically calling their register functions.
    export function registerStellarTools(server: McpServer) { Object.values(getRegisterFunctions(server)).forEach(registerTool => { registerTool(server); }); }
  • Top-level server creation where registerStellarTools(server) is called at line 27, indirectly registering the 'stellar-non-fungible' tool among others.
    export function createServer() { const server = new McpServer( { name: 'OpenZeppelin Contracts Wizard', version, }, { instructions: `\ Tools are provided for different smart contract languages and frameworks: Solidity, Starknet's Cairo, Stellar Soroban, Arbitrum Stylus, and Uniswap v4 Hooks. Each tool generates a smart contract using recommended best practices with OpenZeppelin Contracts libraries, and returns the source code. The tools do not write to disk. If the user requests to create a new smart contract, use the appropriate tool to generate the contract. If the user asks to modify an existing smart contract, use these tools to determine the recommended patterns. Toggle the options in a tool to determine how different features affect the code, then apply the same types of changes to the user's contract. `, }, ); registerSolidityTools(server); registerCairoTools(server); registerStellarTools(server); registerStylusTools(server); registerUniswapHooksTools(server); return server; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/OpenZeppelin/contracts-wizard'

If you have feedback or need assistance with the MCP directory API, please join our Discord server