
Security News
gem.coop Tests Dependency Cooldowns as Package Ecosystems Move to Slow Down Attacks
gem.coop is testing registry-level dependency cooldowns to limit exposure during the brief window when malicious gems are most likely to spread.
@dennisk2025/array-flatten-unflatten
Advanced tools
Provides tools to flatten nested arrays into a single-level array and to unflatten flattened arrays back into nested structures based on a given depth or structure.
Provides tools to flatten nested arrays into a single-level array and to unflatten flattened arrays back into nested structures based on a given depth or structure.
You can use this MCP server via npx or install globally:
npx @dennisk2025/array-flatten-unflatten
or
npm install -g @dennisk2025/array-flatten-unflatten
Add this to your Claude Desktop config file at:
~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.jsonExample configuration:
{
"mcpServers": {
"flatten": {
"command": "npx",
"args": ["@dennisk2025/array-flatten-unflatten"]
}
}
}
Once the MCP server is running (automatically launched by Claude Desktop or manually), you can use the following tools:
Description: Takes a nested array (of any depth) and returns a new array with all the elements in a single level.
Parameters:
nested_array (array, required): The nested array to flatten.Example call:
Tool: flatten-array
Parameters:
{
"nested_array": [[1, 2, [3]], 4, [5, [6, [7, 8]]]]
}
Response:
{
"result": [1, 2, 3, 4, 5, 6, 7, 8]
}
Description: Takes a flat array and reconstructs a nested array structure given a nesting scheme (e.g., depths per group).
Parameters:
flat_array (array, required): The flat array to reshape into nested structure.structure (array of integers, required): The blueprint for nesting (e.g. [2, 2, 2] means 2 arrays of 2 arrays of 2 items each).Example call:
Tool: unflatten-array
Parameters:
{
"flat_array": [1,2,3,4,5,6,7,8],
"structure": [2,2,2]
}
Response:
{
"result": [ [[1,2],[3,4]], [[5,6],[7,8]] ]
}
flatten-array
nested_array (array, required): The nested array to flattenunflatten-array
flat_array (array, required): The flat array to reshapestructure (array of integers, required): The nesting blueprintFAQs
Provides tools to flatten nested arrays into a single-level array and to unflatten flattened arrays back into nested structures based on a given depth or structure.
The npm package @dennisk2025/array-flatten-unflatten receives a total of 3 weekly downloads. As such, @dennisk2025/array-flatten-unflatten popularity was classified as not popular.
We found that @dennisk2025/array-flatten-unflatten demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
gem.coop is testing registry-level dependency cooldowns to limit exposure during the brief window when malicious gems are most likely to spread.

Security News
Following multiple malicious extension incidents, Open VSX outlines new safeguards designed to catch risky uploads earlier.

Research
/Security News
Threat actors compromised four oorzc Open VSX extensions with more than 22,000 downloads, pushing malicious versions that install a staged loader, evade Russian-locale systems, pull C2 from Solana memos, and steal macOS credentials and wallets.