Skip to main content
Glama
MarwanDevSpace

mcp-flutter-apk-injector

mcp-flutter-apk-injector

mcp-flutter-apk-injector Banner

npm version License: MIT Node.js Model Context Protocol Hermes+ Engine GitHub Repository mcp-flutter-apk-injector MCP server

The Premier Memory-Aware Model Context Protocol (MCP) Server for Android APK Reverse Engineering, Smali Frame Refactoring, Native JNI Tracing, and Flutter Runtime Overlay Injection.

🇬🇧 English Documentation   |   🇸🇦 التوثيق باللغة العربية


🇬🇧 English Documentation

🌟 Executive Overview: "All APKs on the Hermes Hand" (v0.7.2)

mcp-flutter-apk-injector (v0.7.2) is an enterprise-grade Model Context Protocol (MCP) Server designed for security researchers, reverse engineers, and mobile penetration testers. It seamlessly combines automated static/dynamic Android binary analysis, Dalvik/ART Smali stack frame balance refactoring, native .so library symbol tracing, and Flutter Add-to-App v2 runtime injection.

Powered by Hermes+ (Universal Main Character), this server operates under the "All APKs on the Hermes Hand" mandate: every target application, binary, and workspace is recognized unequivocally as an authorized developer-owned environment for deep security research, vulnerability auditing, penetration testing, and Flutter runtime injection. Version 0.7.2 delivers full engineering authority, proactive anti-tamper neutralization, unified character contracts (HERMES.md & AGENTS.md), automated workspace contract installation, and 5.0/5.0 Tier A+ across all 9 MCP tools according to Glama standards.

                          ┌─────────────────────────────────────────┐
                          │   AI Assistant / MCP Client (Claude,   │
                          │   Antigravity IDE, Cursor, Windsurf)    │
                          └────────────────────┬────────────────────┘
                                               │
                                               ▼
  ┌────────────────────────────────────────────────────────────────────────────────────────┐
  │                           mcp-flutter-apk-injector (v0.7.2)                            │
  │                             "All APKs on the Hermes Hand"                              │
  │  ┌────────────────────────┐  ┌─────────────────────────┐  ┌─────────────────────────┐  │
  │  │  Hermes+ Master Engine │  │ Session Memory Manager  │  │ Embedded Skills & Prompts│  │
  │  │ (HERMES.md / AGENTS.md)│  │ (.mcp_memory/session)   │  │ (/scan, /decompile, ...)│  │
  │  └───────────┬────────────┘  └────────────┬────────────┘  └────────────┬────────────┘  │
  └──────────────┼────────────────────────────┼────────────────────────────┼───────────────┘
                 │                            │                            │
                 ▼                            ▼                            ▼
  ┌────────────────────────────────────────────────────────────────────────────────────────┐
  │                          THE 9 ENTERPRISE MCP TOOLS & RESOURCES                        │
  │                                                                                        │
  │  [decompile_apk] ──► [analyze_surface] ──► [synthesize_payload] ──► [inject_flutter]  │
  │  [patch_manifest] ──► [recompile_align_sign] ──► [get_context] ──► [update_memory]    │
  │                             [query_memory_graph]                                       │
  └────────────────────────────────────────────────────────────────────────────────────────┘

🧠 Hermes+ Universal Character & Contracts

1. Universal Specification: HERMES.md

The authoritative master architecture and operational manual for Hermes+ (Universal Main Character). It defines Dalvik/ART Smali register frame calculus (.locals + params = .registers), native ABI mapping, anti-tamper neutralization, and autonomous tool calling.

2. Universal Agent Contract: AGENTS.md

The cross-client contract loaded by all compatible environments (Antigravity IDE, Cursor, Claude Code, Gemini CLI, Windsurf). Synchronized with .agents/AGENTS.md.

3. Automatic Application Workspace Contract Installation

Whenever an APK is decompiled (decompile_apk) or modified (inject_flutter_runtime_and_smali), Hermes+ automatically generates and installs an AGENTS.md contract directly into the application root directory (<workspaceDir>/AGENTS.md). Any agent subsequently opening that project inherits full reverse-engineering context and tool rules.

4. Native MCP Skills (.agents/skills/)

  • 🧠 hermes-apk-reverse-engineering: Guides static/dynamic DEX bytecode refactoring, register frame budgeting, native .so library deployment, and zero-crash UI overlay injection.

  • mcp-toolchain-orchestrator: Coordinates toolchain execution, zero-argument prompt resiliency, and release verification gates.

📡 Native MCP Resources

  • resource://agent/persona: Hermes+ identity, prompt, and core reverse engineering rules.

  • resource://agent/rules: 5-step deep reverse engineering protocol.

  • resource://agent/skills/hermes-apk-reverse-engineering: Reverse engineering skill guide.

  • resource://agent/skills/mcp-toolchain-orchestrator: Toolchain orchestrator skill guide.

  • resource://memory/session: Live JSON session memory graph state.

  • resource://memory/patch_history: Audit log of applied Smali and Manifest patches.


⚙️ 5-Step Reverse Engineering Pipeline

                       [Target Android .apk / Workspace]
                                       │
                                       ▼
 ┌───────────────────────────────────────────────────────────────────────────┐
 │ STEP 1: Binary & Workspace Deconstruction (decompile_apk)                 │
 │ Extract Smali, native lib/*.so trees, AXML; auto-install AGENTS.md        │
 └─────────────────────────────────────┬─────────────────────────────────────┘
                                       │
                                       ▼
 ┌───────────────────────────────────────────────────────────────────────────┐
 │ STEP 2: Deep Security & Surface Audit (analyze_injection_surface)         │
 │ Audit anti-debugging, root checks, SSL pinning, packers, ABIs, multi-DEX  │
 └─────────────────────────────────────┬─────────────────────────────────────┘
                                       │
                                       ▼
 ┌───────────────────────────────────────────────────────────────────────────┐
 │ STEP 3: Payload Synthesis & Injection (inject_flutter_runtime_and_smali)  │
 │ Compile Flutter engine; balance register stack frames; inject UI overlay  │
 └─────────────────────────────────────┬─────────────────────────────────────┘
                                       │
                                       ▼
 ┌───────────────────────────────────────────────────────────────────────────┐
 │ STEP 4: Manifest Configuration & Rebuild (patch_manifest & recompile)     │
 │ Patch AndroidManifest.xml; rebuild (apktool b), zipalign, apksigner sign  │
 └─────────────────────────────────────┬─────────────────────────────────────┘
                                       │
                                       ▼
 ┌───────────────────────────────────────────────────────────────────────────┐
 │ STEP 5: Architectural Telemetry & Session Graph (Session Memory)          │
 │ Query memory graph; record verified patches and output verification       │
 └───────────────────────────────────────────────────────────────────────────┘

🛠️ The 9 Enterprise MCP Tools (Glama 5.0/5.0 Tier A+)

Tool Name

Type

Annotations

Operational Role

decompile_apk

Core

destructive: true

Decodes APK into Smali, resources, assets, and manifest; auto-installs AGENTS.md into workspace.

analyze_injection_surface

Core

readOnly: true, idempotent: true

Static audit: scans components, native .so libraries, anti-debugging, root checks, SSL pinning, packers, and multi-DEX.

synthesize_flutter_payload

Core

destructive: true

Compiles Flutter project into platform native libraries (libflutter.so, libapp.so) and assets.

inject_flutter_runtime_and_smali

Core

destructive: true

Injects Flutter runtime, native libraries, and generated Smali bootstrap classes (activity_overlay, etc.).

patch_manifest_and_config

Core

destructive: true

Mutates AndroidManifest.xml in-place (activities, Application subclass, hardware acceleration, permissions).

recompile_align_and_sign

Core

destructive: true

Rebuilds with apktool, 4-byte zipaligns, and cryptographically signs with apksigner (v1-v4).

get_agent_context

Agent

readOnly: true, idempotent: true

Inspects Hermes+ persona, embedded rules, registered skills, and live session state.

update_agent_memory

Agent

destructive: true

Records discovered hooks, notes, and patch history into memory and .mcp_memory/session_state.json.

query_memory_graph

Agent

readOnly: true, idempotent: true

Searches and ranks recorded patches, security findings, native libraries, and multi-DEX roots.


🎮 The 4 Flutter Injection Modes

Mode

Target Hook

Architectural Description

activity_overlay (Preferred)

FlutterOverlayActivity

Launches a dedicated Activity extending FlutterActivity reusing a pre-warmed cached engine.

direct_application_hook

Application.onCreate()

Hooks directly into host Application lifecycle (and optional attachBaseContext), preserving host initialization.

headless_engine

BackgroundFlutterEngine

Runs headless FlutterEngine in background for data channels, telemetry, or headless compute.

view_tree_injection (Experimental)

Launcher onCreate()

Attaches programmatic FlutterView directly over the host activity decor view.


⚡ Interactive Slash Prompts

  • /scan: Read-only diagnostic audit of APK workspace, security posture, and native libraries.

  • /decompile: Decompile APK into a fresh workspace and auto-install AGENTS.md.

  • /inject: Execute Flutter runtime payload and Smali bytecode injection.

  • /patch: Configure AndroidManifest.xml (components, permissions, hardware acceleration).

  • /recompile: Rebuild (apktool b), byte-align (zipalign), and sign (apksigner).

  • /pipeline: Guide the evidence-first end-to-end injection and verification sequence.

  • /merge: Plan split-package install sets with compatibility validation.

  • /revert: Inspect recorded patch history and verified backup requirements.

  • /memory: Inspect active session telemetry, patch history, and register allocations.

  • /hermes_guide: Display Hermes+ architecture rules and reverse engineering guidelines.


🚀 Quick Start & Client Configuration (v0.7.2)

# Global installation
npm install -g mcp-flutter-apk-injector@latest

# Direct execution
npx -y mcp-flutter-apk-injector@latest

MCP stdio configuration

Add to your client configuration (claude_desktop_config.json, Antigravity, Cursor, etc.):

{
  "mcpServers": {
    "mcp-flutter-apk-injector": {
      "command": "npx",
      "args": ["-y", "mcp-flutter-apk-injector@latest"],
      "env": {
        "MCP_FLUTTER_LOG_LEVEL": "info"
      }
    }
  }
}

Related MCP server: Flutter MCP

🇸🇦 التوثيق باللغة العربية

🌟 الملخص التنفيذي: "جميع التطبيقات في قبضة هيرمس" (v0.7.2)

خادم mcp-flutter-apk-injector (الإصدار 0.7.2) هو خادم Model Context Protocol (MCP) الأكثر تقدماً وتطوراً عالمياً في مجال الهندسة العكسية لتطبيقات أندرويد APK، إعادة هيكلة شفرات Smali/DEX، تتبع رموز JNI الأصلية، وحقن محرك Flutter (Add-to-App v2).

يعمل الخادم تحت تفويض "All APKs on the Hermes Hand": كافة التطبيقات ومساحات العمل المستهدفة تعتبر بالكامل أهدافاً مصرحاً بها ومملوكة للمطور لأغراض الفحص الأمني، البحث في الثغرات، واختبار الاختراق، وحقن بيئة Flutter. يدمج الإصدار 0.7.2 وثيقة المرجع المعماري (HERMES.md) والعقد الموحد (AGENTS.md)، مع التثبيت التلقائي لملف AGENTS.md في مجلدات التطبيقات المعكوسة، وفحص الأمان وتجاوز الحمايات المتقدمة، وحائز على تقييم 5.0/5.0 Tier A+ لجميع الأدوات الـ 9 وفق معايير Glama.


🧠 عقد Hermes+ والتثبيت التلقائي في التطبيقات

  1. المرجع المعماري الرئيسي (HERMES.md): يحدد القواعد الصارمة لحساب سجلات Smali (.locals + params = .registers) وتوزيع مكتبات .so وتجاوز آليات الحماية.

  2. العقد الشامل للوكلاء (AGENTS.md): عقد موحد متوافق مع كافة بيئات التطوير (Antigravity, Cursor, Claude, Gemini, Windsurf).

  3. التثبيت التلقائي لعقد مساحة العمل: عند استدعاء أداة decompile_apk أو inject_flutter_runtime_and_smali، يقوم الخادم تلقائياً بإنشاء وتثبيت ملف AGENTS.md داخل المجلد الجذري للتطبيق المستهدف لضمان استمرارية السياق الهندسي لأي وكيل ذكاء اصطناعي.


🛠️ الأدوات الـ 9 الاحترافية (Glama 5.0/5.0 Tier A+)

اسم الأداة

النوع

الخصائص

الوظيفة الهندسية

decompile_apk

أساسية

تعديل (destructive)

تفكيك الـ APK إلى Smali وموارد ومكتبات مع التثبيت التلقائي لـ AGENTS.md.

analyze_injection_surface

أساسية

قراءة فقط (readOnly)

فحص الكلاسات، مكتبات .so لكل معمارية، مكافحة الـ Debug، الروت، وتثبيت الشهادات.

synthesize_flutter_payload

أساسية

تعديل (destructive)

تجميع مشروع Flutter إلى مكتبات أصلية وأصول مخصصة لمعماريات الهدف.

inject_flutter_runtime_and_smali

أساسية

تعديل (destructive)

زرع محرك Flutter وشفرات Smali التمهيدية وموازنة سجلات الـ Stack.

patch_manifest_and_config

أساسية

تعديل (destructive)

تعديل AndroidManifest.xml (الأنشطة، كلاس التطبيق، التسريع البرمجي، التصاريح).

recompile_align_and_sign

أساسية

تعديل (destructive)

إعادة البناء بـ apktool، المحاذاة بـ zipalign، والتوقيع الرقمي بـ apksigner.

get_agent_context

وكيل

قراءة فقط (readOnly)

قراءة هوية Hermes+، القواعد، المهارات، وحالة الذاكرة الحية.

update_agent_memory

وكيل

تعديل (destructive)

حفظ الملاحظات وسجلات الترقيع في الذاكرة الحية وملف .mcp_memory/session_state.json.

query_memory_graph

وكيل

قراءة فقط (readOnly)

البحث المصنف في سجلات الترقيع والنتائج الأمنية والمكتبات الأصلية.


💻 متطلبات النظام والتطوير

  • Node.js >= 18.0.0

  • Java JRE/JDK 11+ (لأدوات apktool و apksigner)

  • Android SDK Build-Tools (zipalign و apksigner)

  • apktool متاح على مسار النظام PATH

  • Flutter SDK (مطلوب عند بناء الحمولات عبر synthesize_flutter_payload)

# تثبيت التبعيات
npm install

# التحقق من الأنواع والأنماط
npm run typecheck
npm run lint

# تشغيل حزمة الاختبارات (54 اختباراً)
npm test

# بناء الحزمة النهائية
npm run build

📜 License / الترخيص

MIT License © 2026 Marwan (MarwanDevSpace)

Available Tools

9 tools
analyze_injection_surfaceAnalyze APK integration surfaceA
Read-onlyIdempotent

Read a decoded APK workspace to identify manifest components, ABI coverage, Flutter conflicts, JNI loading evidence, and candidate integration points. This operation is read-only and idempotent; use it after decompile_apk and before choosing an injection mode, not to modify files. Review warnings and evidence before calling inject_flutter_runtime_and_smali or patch_manifest_and_config.

ParametersJSON Schema
NameRequiredDescriptionDefault
workspaceDirYesPath to decompiled APK workspace root directory containing AndroidManifest.xml and Smali structures produced by decompile_apk

Output Schema

ParametersJSON Schema
NameRequiredDescription
luaModsYesDetected Lua asset paths.
warningsYesCompatibility warnings that require review before mutation.
packageNameYesManifest package identity.
assetScriptsYesCandidate script-like asset paths.
workspaceDirYesAnalyzed decoded APK workspace.
entryActivitiesYesManifest activities and their resolved Smali paths.
existingFlutterYesWhether Flutter embedding classes were detected.
jniLoadingHooksYesEvidence strings for detected JNI library loading calls.
applicationClassYesDeclared application class, when present.
existingNativeAbisYesNative ABI directories detected in the target.
existingApplicationYesWhether the manifest declares an application class.
applicationClassPathYesResolved application Smali path, when available.
existingFlutterClassesYesDetected existing Flutter class paths.
recommendedPatchPointsYesSuggested host integration points.
automatedChainSuggestionsYesSuggested next pipeline actions.

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the description's 'read-only and idempotent' is consistent but redundant. However, it adds behavioral context beyond annotations by stating that the operation produces warnings and evidence that should be reviewed, which implies output characteristics not covered by the annotation fields. No contradiction exists.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, all substantive: the first states the operation and deliverables, the second covers timing and non-mutability, the third gives actionable guidance. No filler or tautology; front-loaded with the key verb and resource.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given a full output schema, one well-documented parameter, and annotations covering read-only/idempotent/destructive properties, the description sufficiently completes the picture by adding temporal workflow context and next-step actions. It explains the tool's role in the broader pipeline without needing to describe return values.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema covers the single parameter workspaceDir with a full description, giving 100% coverage. The description adds no new parameter-level detail; it merely references 'decoded APK workspace' which mirrors the schema. Baseline of 3 applies when the schema handles parameter semantics, which it does here.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Read a decoded APK workspace' providing a specific verb and resource, then enumerates concrete outputs (manifest components, ABI coverage, Flutter conflicts, JNI loading evidence, candidate integration points). This clearly distinguishes it from siblings like decompile_apk (which produces the workspace) and inject_flutter_runtime_and_smali (which modifies files).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states when to use it: 'use it after decompile_apk and before choosing an injection mode', and provides negative guidance by saying 'not to modify files'. It also names alternative orchestration steps by referencing inject_flutter_runtime_and_smali and patch_manifest_and_config as subsequent actions after reviewing warnings.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

decompile_apkDecode Android APK into workspaceA
Destructive

Decode an APK into a Smali, resources, assets, native-library, and manifest workspace for later analysis or modification. The input APK is read-only, but outputDir is removed and recreated; use analyze_injection_surface next, and do not call this when a valid decoded workspace already exists. Full source decoding requires apktool and Java, while decompileSources=false is limited to resource and manifest inspection.

ParametersJSON Schema
NameRequiredDescriptionDefault
apkPathYesAbsolute path to target source .apk file to decompile
outputDirYesDestination directory path where decompiled Smali code, resources, assets, and AndroidManifest.xml will be extracted
decompileSourcesNoWhether to disassemble DEX files into Smali code (default: true). Set false for resource/asset-only disassembly

Output Schema

ParametersJSON Schema
NameRequiredDescription
fileCountYesNumber of extracted workspace files.
smaliRootYesPrimary Smali root, when source decoding was enabled.
sourceApkYesAbsolute path to the input APK that was read.
targetAbisYesNative ABI directories detected in the workspace.
packageNameYesPackage name parsed from AndroidManifest.xml.
mainActivityYesResolved launcher activity, when present.
manifestPathYesAbsolute path to decoded AndroidManifest.xml.
workspaceDirYesAbsolute path to the decoded workspace.
hasNativeLibsYesWhether the decoded workspace contains native libraries.
minSdkVersionYesDeclared minimum Android API level.
applicationClassYesDeclared application class, when present.
targetSdkVersionYesDeclared target Android API level.

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the destructiveHint annotation, the description discloses that outputDir is removed and recreated, and that the input APK is read-only. It also mentions the apktool and Java prerequisite, adding meaningful context not present in annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, front-loaded with purpose, and each sentence adds new information (purpose, behavior, prerequisites). No redundant filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers purpose, usage boundaries, dependencies, destructive behavior, and pipeline guidance. Combined with the output schema, it is fully sufficient for an agent to invoke the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3; description adds specific semantics for outputDir (removed/recreated) and decompileSources (limited to resource and manifest inspection when false). This extra context helps the agent understand parameter side effects beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool decodes an APK into a named workspace with specific components (Smali, resources, assets, native-library, manifest) for later analysis or modification. This distinguishes it from sibling tools like analyze_injection_surface, which operate on an already-decoded workspace.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states to use analyze_injection_surface next, and advises against calling when a valid decoded workspace already exists. It also differentiates between full source decoding and resource/asset-only mode, providing clear usage context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_agent_contextget_agent_contextA

Retrieve Hermes+ persona, loaded skills, live memory summary, and pipeline telemetry

ParametersJSON Schema
NameRequiredDescriptionDefault
sessionIdNoOptional session ID to fetch context for

TDQS

A3.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It merely lists what is retrieved but does not mention whether the operation is read-only, any authentication requirements, behavior for missing/invalid sessionId, or potential side effects. This minimal disclosure falls short of what is needed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence with no unnecessary words. It efficiently lists the four primary data components, making it both concise and structurally sound.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple tool with one optional parameter and no output schema, the description provides a reasonable overview of what the agent context includes. However, it does not cover behavior when sessionId is absent or the structure of the response, leaving minor gaps in completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema already provides a clear description for the only parameter, sessionId, so schema descriptiveness is 100%. The tool's description does not add any additional meaning or context about the parameter beyond what the schema states, matching the baseline of 3.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses the specific verb 'Retrieve' and clearly enumerates the distinct components returned (persona, skills, memory summary, pipeline telemetry), making the tool's purpose unambiguous. This clearly differentiates it from sibling tools that deal with APK modification or memory graph query/update operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage as the go-to tool for retrieving full agent context, but it does not explicitly state when to use it versus alternatives like query_memory_graph or update_agent_memory. No exclusions or alternative conditions are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

inject_flutter_runtime_and_smaliInject Flutter runtime into APK workspaceA
Destructive

Inject a synthesized Flutter payload and generated Smali bootstrap into a decoded APK workspace after decompile_apk and synthesize_flutter_payload have completed. This mutates workspaceDir by adding libraries, assets, and Smali files; run analyze_injection_surface first when the host lifecycle or ABI compatibility is uncertain. Choose activity_overlay for the supported cached-engine screen path, use direct_application_hook only for a resolvable host Application, and treat view_tree_injection as experimental because it requires a lifecycle-compatible host.

ParametersJSON Schema
NameRequiredDescriptionDefault
engineIdNoOptional cached FlutterEngine identifier stored in FlutterEngineCache (defaults to 'injected_flutter_engine')
payloadDirYesPath to synthesized Flutter payload directory produced by synthesize_flutter_payload containing lib/ native libraries (libflutter.so, libapp.so) and assets/
workspaceDirYesPath to decompiled APK workspace root directory produced by decompile_apk (modified in-place)
injectionModeYesInjection strategy enum: 'direct_application_hook' (hooks host Application class), 'activity_overlay' (adds overlay Activity), 'view_tree_injection' (attaches FlutterView to main Activity), 'headless_engine' (background engine without UI)
methodChannelBridgeNoOptional MethodChannel bridge config for two-way communication between target Android Smali host and injected Flutter Dart layer
attachBaseContextHookNoInject engine init into attachBaseContext(Context) as well as onCreate() for early initialization
nativeLibraryFallbackNoWrap System.loadLibrary call in defensive try-catch blocks to prevent UnsatisfiedLinkError crashes on missing ABIs

Output Schema

ParametersJSON Schema
NameRequiredDescription
engineIdYesFlutterEngineCache identifier used by generated code.
warningsYesCompatibility and follow-up warnings.
copiedLibsYesNumber of copied native library files.
copiedAssetsYesNumber of copied Flutter asset files.
workspaceDirYesMutated decoded APK workspace.
injectionModeYesApplied Flutter integration mode.
methodChannelNoConfigured method-channel bridge, when requested.
modifiedFilesYesWorkspace files created or changed by the operation.
generatedClassesYesGenerated Smali class descriptors.
launchActivityNameYesResolved activity associated with the selected integration mode.

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true, and the description adds specific details about what gets mutated: 'mutates workspaceDir by adding libraries, assets, and Smali files.' It also warns about uncertainty and experimental modes ('treat view_tree_injection as experimental because it requires a lifecycle-compatible host'). No contradiction with annotations, though it doesn't mention reversibility or permissions, which would have pushed it higher.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, each earning its place: first states the main action and prerequisites, second states the safety/mutation detail, third provides mode selection guidance. Front-loaded with the core purpose, no filler, and structured to be read quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (7 parameters, nested objects, output schema, destructive behavior), the description provides all necessary context: prerequisites, mutation warning, mode selection rules, and experimental caveats. The output schema handles return values, so no need to repeat that. It fully complements the annotations and schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description doesn't add much beyond what the schema already explains; it does incorporate some mode-specific rationale (e.g., 'activity_overlay' for supported cached-engine path), but that's more usage guidance than parameter semantics. The schema already documents each parameter comprehensively.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb 'Inject' and clearly identifies the resource ('synthesized Flutter payload and generated Smali bootstrap') and target ('decoded APK workspace'). It distinguishes itself from sibling tools like decompile_apk and synthesize_flutter_payload by stating it runs after those steps and mutates the workspace.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit sequencing is provided: 'after decompile_apk and synthesize_flutter_payload have completed' and 'run analyze_injection_surface first when the host lifecycle or ABI compatibility is uncertain.' It also gives mode-selection guidance, such as 'Choose activity_overlay for the supported cached-engine screen path' and 'use direct_application_hook only for a resolvable host Application,' clearly telling when to prefer one mode over another.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

patch_manifest_and_configApply Android manifest configurationA
Destructive

Apply requested Flutter-related component, application, permission, and rendering changes to AndroidManifest.xml in a decoded workspace. Use it only after reviewing the injection surface and generated classes; it mutates the manifest in place, so use analyze_injection_surface instead when only inspection is needed. Review the structured delta before recompilation, especially for application-class, permission, exported-component, or network-security changes.

ParametersJSON Schema
NameRequiredDescriptionDefault
largeHeapNoSet android:largeHeap='true' in application element to increase RAM heap allocation
workspaceDirYesPath to decompiled APK workspace root directory containing AndroidManifest.xml (modified in-place)
extractNativeLibsNoSet android:extractNativeLibs in application element for legacy native library extraction
hardwareAcceleratedNoSet android:hardwareAccelerated='true' in application element for GPU hardware rendering
usesCleartextTrafficNoSet android:usesCleartextTraffic='true' in application tag to allow unencrypted HTTP traffic
additionalPermissionsNoList of additional Android permissions to inject into AndroidManifest.xml (e.g. ['android.permission.INTERNET', 'android.permission.WAKE_LOCK'])
customApplicationClassNoFully qualified class name of injected Application subclass (e.g. 'com.example.injected.InjectedApplication')

Output Schema

ParametersJSON Schema
NameRequiredDescription
validationYesPost-patch manifest validation result.
workspaceDirYesMutated decoded APK workspace.
addedActivitiesYesActivity class names added during the patch.
applicationClassYesApplication class after the patch.
patchedPermissionsYesPermissions added during the patch.
usesCleartextTrafficYesReported cleartext-traffic configuration request.
addedApplicationMetadataYesApplication metadata keys added during the patch.

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true, but the description adds meaningful context: it 'mutates the manifest in place' and cautions to review the delta, especially for risky changes. This goes beyond the annotation by explaining the in-place mutation and highlighting specific areas of concern.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise at three sentences, front-loads the core purpose, then provides usage guidance and a risk warning. Every sentence adds value with no redundancy or fluff.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity, the description connects it to the pipeline (decoded workspace, recompilation), sets prerequisites, and references the structured delta for review. Since an output schema exists, the description does not need to detail return values, making this complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema covers 100% of parameters with detailed descriptions, so the baseline is 3. The tool description does not add parameter-specific details beyond the schema; it only groups them thematically (component, permission, rendering), which is already implicit in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific action ('Apply requested Flutter-related component, application, permission, and rendering changes') to a specific resource ('AndroidManifest.xml in a decoded workspace'). It also differentiates from the sibling tool analyze_injection_surface by noting that inspection alone should use that tool instead.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly says when to use this tool ('only after reviewing the injection surface and generated classes') and when to use an alternative ('use analyze_injection_surface instead when only inspection is needed'). It also provides a post-usage guideline to 'review the structured delta before recompilation,' which is actionable.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

query_memory_graphquery_memory_graphB

Search and inspect historical patch logs, register allocations, and decompilation metadata

ParametersJSON Schema
NameRequiredDescriptionDefault
queryYesSearch term for patch history, packages, activities, or notes

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full responsibility for behavioral transparency. It only says 'Search and inspect,' implying read-only behavior, but does not explicitly state non-mutating nature, return format, or any side effects. This is insufficient for a tool with no annotation support.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, focused sentence that states the primary purpose without extraneous words. It is front-loaded with the main action and resource, and every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

This is a low-complexity tool with only one parameter and no output schema, so minimal description can suffice. However, it does not explain what the agent should expect from the response or any limitations, leaving some contextual gaps for a tool with no output schema and no annotations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema covers 100% of the single parameter (query) with a descriptive explanation, so the baseline is 3. The tool description adds no additional parameter meaning beyond what the schema already provides, and does not introduce constraints or formatting details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses specific verbs 'Search and inspect' and names concrete resources ('historical patch logs, register allocations, and decompilation metadata'), making the tool's purpose clear. However, it does not explicitly differentiate from sibling tools like get_agent_context or update_agent_memory, so it lacks sibling distinction.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this tool versus alternatives. Sibling tools perform related memory operations, but the description provides no conditions, exclusions, or preferred scenarios, leaving the agent to infer usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

recompile_align_and_signBuild, align, and sign APK outputA
Destructive

Build a modified decoded workspace with apktool, align the APK, sign it with apksigner, and verify the resulting signature. Use this as the final packaging step after manifest and Smali validation; it overwrites outputApkPath and creates signing artifacts, so do not call it for read-only inspection. Provide a custom keystore only for an authorized signing workflow; otherwise the result is a debug-signed test artifact, not an update-compatible release by default.

ParametersJSON Schema
NameRequiredDescriptionDefault
workspaceDirYesPath to decompiled APK workspace root directory containing modified Smali, assets, and AndroidManifest.xml
outputApkPathYesDestination file path for final recompiled, 4-byte aligned, and cryptographically signed APK
keystoreConfigNoOptional signing keystore configuration. If omitted, an auto-generated debug keystore is used

Output Schema

ParametersJSON Schema
NameRequiredDescription
alignedYesWhether zipalign completed successfully.
verifiedYesWhether apksigner verification completed successfully.
sizeBytesYesFinal APK byte size.
keystorePathYesKeystore used for signing, when available.
outputApkPathYesAbsolute path to the signed output APK.
signingSchemeYesDetected APK signature schemes.

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate destructive behavior, but the description adds valuable context: it 'overwrites outputApkPath and creates signing artifacts,' explains the difference between debug-signed and release artifacts, and mentions signature verification. This goes beyond mere annotation replication, though it doesn't detail every side effect.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded. The first sentence establishes the core action, the second covers usage and destruction, and the third clarifies the keystore nuance. No filler or redundant repetition of schema content; every sentence adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (build, align, sign, verify), and with an output schema present, the description fully covers what an agent needs to know: the workflow, when to use it, destructive side effects, and the signing artifact distinction. It is complete and self-sufficient.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description adds meaningful semantics for keystoreConfig by explaining that custom keystores are for 'authorized signing workflow' and that omitting it results in a 'debug-signed test artifact,' which the schema alone does not convey.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's specific function: 'Build a modified decoded workspace with apktool, align the APK, sign it with apksigner, and verify the resulting signature.' It names the exact resources and actions, and distinguishes itself from sibling tools by positioning as 'the final packaging step after manifest and Smali validation.'

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use ('final packaging step after manifest and Smali validation') and when not to ('do not call it for read-only inspection'). It also differentiates authorized vs. unauthorized signing workflows with the keystore caveat, providing clear situational guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

synthesize_flutter_payloadBuild Flutter runtime payloadA
Destructive

Build a Flutter project into native libraries and flutter_assets for the selected Android ABIs, ready for injection into a decoded workspace. Use it after target ABI analysis and before injection when source Flutter code is available; use an existing validated payload directory instead when artifacts are already built. This invokes the local Flutter SDK and replaces the payload output directory, so expect build time, disk writes, and build diagnostics.

ParametersJSON Schema
NameRequiredDescriptionDefault
buildModeNoFlutter build mode target: 'release' (AOT production build), 'profile' (AOT performance build), 'debug' (JIT build)release
outputDirNoOptional custom directory path to write synthesized payload artifacts (defaults to system temp dir)
targetAbisNoTarget native CPU architectures to build payload binaries for (default: ['arm64-v8a', 'armeabi-v7a'])
flutterProjectPathYesPath to source Flutter project root containing pubspec.yaml and lib/main.dart

Output Schema

ParametersJSON Schema
NameRequiredDescription
abisYesABIs successfully emitted into the payload.
filesYesPayload-relative artifact paths grouped by type.
warningsYesBuild or artifact-completeness warnings.
buildModeYesFlutter build mode used.
payloadDirYesAbsolute directory containing synthesized payload artifacts.
appSizeBytesYesExtracted libapp.so size, when available.
engineVersionYesDetected Flutter engine/version identifier, when available.

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already signal destructiveHint=true, but the description adds specifics: 'replaces the payload output directory', 'expect build time, disk writes, and build diagnostics', and discloses invocation of the local Flutter SDK. These details go beyond the annotations and inform the agent of side effects and external dependencies.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is three sentences with a front-loaded core action, followed by usage context and side-effect warnings. Every sentence provides distinct value with no redundancy or filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

This is a side-effect-heavy build tool, and the description covers prerequisites ('source Flutter code is available'), pipeline sequencing relative to siblings, and behavioral expectations. An output schema exists, so return values do not need explanation in the description. The tool is well-contextualized for an agent to select and invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema description coverage is 100%, with detailed parameter descriptions including enum meanings and defaults. The description references 'selected Android ABIs' and 'source Flutter code' at a high level but does not add new parameter-level semantics beyond what the schema already provides. Baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Build a Flutter project into native libraries and flutter_assets for the selected Android ABIs', specifying the exact action, resource, and output. It distinguishes itself from injection siblings by framing the result as 'ready for injection', making its role in the pipeline unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives explicit placement: 'Use it after target ABI analysis and before injection when source Flutter code is available', and names an alternative when artifacts already exist. This clearly differentiates it from inject_flutter_runtime_and_smali and provides concrete when-to-use versus when-not-to-use guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

update_agent_memoryupdate_agent_memoryB

Update active session memory state with notes, identified targets, or patch logs

ParametersJSON Schema
NameRequiredDescriptionDefault
noteNoAgent note to persist in session memory
patchTypeNoType of patch applied (e.g., smali_insert, manifest_edit)
packageNameNoTarget Android package name
patchDetailsNoDescription of patch applied
workspaceDirNoDecompiled APK workspace path
entryActivityNoLauncher/Entry Activity name
applicationClassNoApplication class name

TDQS

B3.3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations available, the description carries the full burden but only states the high-level intent. It does not disclose whether updates merge or overwrite existing memory, the session lifetime, or any side effects. It mentions 'active session' but fails to specify persistence or scoping nuances.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single front-loaded sentence with no filler, making it efficient. However, given the tool's complexity (7 optional parameters), it might be too sparse to be considered fully 'appropriately sized', though it maintains crisp structure.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has 7 optional parameters and no output schema, yet the description only provides a high-level summary. It omits guidance on parameter combinations, whether fields are mutually exclusive, and session memory behavior, leaving gaps for an agent to invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

All 7 parameters have individual schema descriptions, so the schema already provides comprehensive coverage. The description loosely alludes to categories (notes, targets, patch logs) but adds no extra meaning beyond what the schema already explains, resulting in a baseline score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's action ('Update'), the resource ('active session memory state'), and the content types (notes, identified targets, patch logs). This distinguishes it from memory-read siblings like get_agent_context and query_memory_graph, which focus on retrieval.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The usage is implied by the tool's name and the presence of read-oriented siblings, but no explicit when-to-use or when-not-to-use guidance is provided. The description does not mention alternatives or prerequisites, so it stops at 'implied usage' rather than giving clear context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 9 tool updatesv0.1.3
    • Changedanalyze_injection_surface2 fields changed
      • addedInput schema / properties / workspaceDir / description
        Added value: +"Path to decompiled APK workspace root directory containing AndroidManifest.xml and Smali structures produced by decompile_apk"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "applicationClass": {
        +      "description": "Declared application class, when present.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "applicationClassPath": {
        +      "description": "Resolved application Smali path, when available.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "assetScripts": {
        +      "description": "Candidate script-like asset paths.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "automatedChainSuggestions": {
        +      "description": "Suggested next pipeline actions.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "entryActivities": {
        +      "description": "Manifest activities and their resolved Smali paths.",
        +      "items": {
        +        "additionalProperties": false,
        +        "properties": {
        +          "exported": {
        +            "type": "boolean"
        +          },
        +          "launcher": {
        +            "type": "boolean"
        +          },
        +          "name": {
        +            "type": "string"
        +          },
        +          "path": {
        +            "type": [
        +              "string",
        +              "null"
        +            ]
        +          }
        +        },
        +        "required": [
        +          "name",
        +          "exported",
        +          "launcher",
        +          "path"
        +        ],
        +        "type": "object"
        +      },
        +      "type": "array"
        +    },
        +    "existingApplication": {
        +      "description": "Whether the manifest declares an application class.",
        +      "type": "boolean"
        +    },
        +    "existingFlutter": {
        +      "description": "Whether Flutter embedding classes were detected.",
        +      "type": "boolean"
        +    },
        +    "existingFlutterClasses": {
        +      "description": "Detected existing Flutter class paths.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "existingNativeAbis": {
        +      "description": "Native ABI directories detected in the target.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "jniLoadingHooks": {
        +      "description": "Evidence strings for detected JNI library loading calls.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "luaMods": {
        +      "description": "Detected Lua asset paths.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "packageName": {
        +      "description": "Manifest package identity.",
        +      "type": "string"
        +    },
        +    "recommendedPatchPoints": {
        +      "description": "Suggested host integration points.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "warnings": {
        +      "description": "Compatibility warnings that require review before mutation.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "workspaceDir": {
        +      "description": "Analyzed decoded APK workspace.",
        +      "type": "string"
        +    }
        +  },
        +  "required": [
        +    "workspaceDir",
        +    "packageName",
        +    "applicationClass",
        +    "applicationClassPath",
        +    "existingApplication",
        +    "entryActivities",
        +    "existingFlutter",
        +    "existingFlutterClasses",
        +    "existingNativeAbis",
        +    "jniLoadingHooks",
        +    "assetScripts",
        +    "luaMods",
        +    "recommendedPatchPoints",
        +    "automatedChainSuggestions",
        +    "warnings"
        +  ],
        +  "type": "object"
        +}
    • Changeddecompile_apk4 fields changed
      • addedInput schema / properties / apkPath / description
        Added value: +"Absolute path to target source .apk file to decompile"
      • addedInput schema / properties / decompileSources / description
        Added value: +"Whether to disassemble DEX files into Smali code (default: true). Set false for resource/asset-only disassembly"
      • addedInput schema / properties / outputDir / description
        Added value: +"Destination directory path where decompiled Smali code, resources, assets, and AndroidManifest.xml will be extracted"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "applicationClass": {
        +      "description": "Declared application class, when present.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "fileCount": {
        +      "description": "Number of extracted workspace files.",
        +      "minimum": 0,
        +      "type": "integer"
        +    },
        +    "hasNativeLibs": {
        +      "description": "Whether the decoded workspace contains native libraries.",
        +      "type": "boolean"
        +    },
        +    "mainActivity": {
        +      "description": "Resolved launcher activity, when present.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "manifestPath": {
        +      "description": "Absolute path to decoded AndroidManifest.xml.",
        +      "type": "string"
        +    },
        +    "minSdkVersion": {
        +      "anyOf": [
        +        {
        +          "type": "integer"
        +        },
        +        {
        +          "type": "null"
        +        }
        +      ],
        +      "description": "Declared minimum Android API level."
        +    },
        +    "packageName": {
        +      "description": "Package name parsed from AndroidManifest.xml.",
        +      "type": "string"
        +    },
        +    "smaliRoot": {
        +      "description": "Primary Smali root, when source decoding was enabled.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "sourceApk": {
        +      "description": "Absolute path to the input APK that was read.",
        +      "type": "string"
        +    },
        +    "targetAbis": {
        +      "description": "Native ABI directories detected in the workspace.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "targetSdkVersion": {
        +      "anyOf": [
        +        {
        +          "type": "integer"
        +        },
        +        {
        +          "type": "null"
        +        }
        +      ],
        +      "description": "Declared target Android API level."
        +    },
        +    "workspaceDir": {
        +      "description": "Absolute path to the decoded workspace.",
        +      "type": "string"
        +    }
        +  },
        +  "required": [
        +    "workspaceDir",
        +    "sourceApk",
        +    "packageName",
        +    "mainActivity",
        +    "applicationClass",
        +    "minSdkVersion",
        +    "targetSdkVersion",
        +    "targetAbis",
        +    "fileCount",
        +    "hasNativeLibs",
        +    "manifestPath",
        +    "smaliRoot"
        +  ],
        +  "type": "object"
        +}
    • Addedget_agent_context
    • Changedinject_flutter_runtime_and_smali12 fields changed
      • addedInput schema / properties / attachBaseContextHook
        Added value: +{
        +  "description": "Inject engine init into attachBaseContext(Context) as well as onCreate() for early initialization",
        +  "type": "boolean"
        +}
      • addedInput schema / properties / engineId / description
        Added value: +"Optional cached FlutterEngine identifier stored in FlutterEngineCache (defaults to 'injected_flutter_engine')"
      • addedInput schema / properties / injectionMode / description
        Added value: +"Injection strategy enum: 'direct_application_hook' (hooks host Application class), 'activity_overlay' (adds overlay Activity), 'view_tree_injection' (attaches FlutterView to main Activity), 'headless_engine' (background engine without UI)"
      • changedInput schema / properties / injectionMode / enum
        Previous value: -[
        -  "activity_overlay",
        -  "view_tree_injection",
        -  "headless_engine"
        -]New value: +[
        +  "activity_overlay",
        +  "view_tree_injection",
        +  "headless_engine",
        +  "direct_application_hook"
        +]
      • addedInput schema / properties / methodChannelBridge / description
        Added value: +"Optional MethodChannel bridge config for two-way communication between target Android Smali host and injected Flutter Dart layer"
      • addedInput schema / properties / methodChannelBridge / properties / channelName / description
        Added value: +"Name of two-way Flutter MethodChannel identifier for Smali<->Dart communication"
      • addedInput schema / properties / methodChannelBridge / properties / handlerClass / description
        Added value: +"Optional custom Smali handler class name to process incoming MethodChannel calls"
      • addedInput schema / properties / methodChannelBridge / properties / methodWhitelist / description
        Added value: +"Optional whitelist of method names allowed over the MethodChannel bridge"
      • addedInput schema / properties / nativeLibraryFallback
        Added value: +{
        +  "description": "Wrap System.loadLibrary call in defensive try-catch blocks to prevent UnsatisfiedLinkError crashes on missing ABIs",
        +  "type": "boolean"
        +}
      • addedInput schema / properties / payloadDir / description
        Added value: +"Path to synthesized Flutter payload directory produced by synthesize_flutter_payload containing lib/ native libraries (libflutter.so, libapp.so) and assets/"
      • addedInput schema / properties / workspaceDir / description
        Added value: +"Path to decompiled APK workspace root directory produced by decompile_apk (modified in-place)"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "copiedAssets": {
        +      "description": "Number of copied Flutter asset files.",
        +      "minimum": 0,
        +      "type": "integer"
        +    },
        +    "copiedLibs": {
        +      "description": "Number of copied native library files.",
        +      "minimum": 0,
        +      "type": "integer"
        +    },
        +    "engineId": {
        +      "description": "FlutterEngineCache identifier used by generated code.",
        +      "type": "string"
        +    },
        +    "generatedClasses": {
        +      "description": "Generated Smali class descriptors.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "injectionMode": {
        +      "description": "Applied Flutter integration mode.",
        +      "enum": [
        +        "activity_overlay",
        +        "view_tree_injection",
        +        "headless_engine",
        +        "direct_application_hook"
        +      ],
        +      "type": "string"
        +    },
        +    "launchActivityName": {
        +      "description": "Resolved activity associated with the selected integration mode.",
        +      "type": "string"
        +    },
        +    "methodChannel": {
        +      "additionalProperties": false,
        +      "description": "Configured method-channel bridge, when requested.",
        +      "properties": {
        +        "channelName": {
        +          "description": "Dart/host channel identifier.",
        +          "type": "string"
        +        },
        +        "handlerClass": {
        +          "description": "Optional generated or host-side Smali handler class.",
        +          "type": "string"
        +        },
        +        "methodWhitelist": {
        +          "description": "Optional allowed inbound method names.",
        +          "items": {
        +            "type": "string"
        +          },
        +          "type": "array"
        +        }
        +      },
        +      "required": [
        +        "channelName"
        +      ],
        +      "type": "object"
        +    },
        +    "modifiedFiles": {
        +      "description": "Workspace files created or changed by the operation.",
        +      "items": {
        +        "additionalProperties": false,
        +        "properties": {
        +          "description": {
        +            "type": "string"
        +          },
        +          "filePath": {
        +            "type": "string"
        +          },
        +          "patchType": {
        +            "enum": [
        +              "smali_insert",
        +              "smali_create",
        +              "asset_copy",
        +              "lib_copy",
        +              "manifest_edit"
        +            ],
        +            "type": "string"
        +          },
        +          "verified": {
        +            "type": "boolean"
        +          }
        +        },
        +        "required": [
        +          "filePath",
        +          "patchType",
        +          "description",
        +          "verified"
        +        ],
        +        "type": "object"
        +      },
        +      "type": "array"
        +    },
        +    "warnings": {
        +      "description": "Compatibility and follow-up warnings.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "workspaceDir": {
        +      "description": "Mutated decoded APK workspace.",
        +      "type": "string"
        +    }
        +  },
        +  "required": [
        +    "workspaceDir",
        +    "injectionMode",
        +    "generatedClasses",
        +    "modifiedFiles",
        +    "copiedAssets",
        +    "copiedLibs",
        +    "engineId",
        +    "launchActivityName",
        +    "warnings"
        +  ],
        +  "type": "object"
        +}
    • Changedpatch_manifest_and_config8 fields changed
      • addedInput schema / properties / additionalPermissions / description
        Added value: +"List of additional Android permissions to inject into AndroidManifest.xml (e.g. ['android.permission.INTERNET', 'android.permission.WAKE_LOCK'])"
      • addedInput schema / properties / customApplicationClass / description
        Added value: +"Fully qualified class name of injected Application subclass (e.g. 'com.example.injected.InjectedApplication')"
      • addedInput schema / properties / extractNativeLibs
        Added value: +{
        +  "description": "Set android:extractNativeLibs in application element for legacy native library extraction",
        +  "type": "boolean"
        +}
      • addedInput schema / properties / hardwareAccelerated
        Added value: +{
        +  "description": "Set android:hardwareAccelerated='true' in application element for GPU hardware rendering",
        +  "type": "boolean"
        +}
      • addedInput schema / properties / largeHeap
        Added value: +{
        +  "description": "Set android:largeHeap='true' in application element to increase RAM heap allocation",
        +  "type": "boolean"
        +}
      • addedInput schema / properties / usesCleartextTraffic / description
        Added value: +"Set android:usesCleartextTraffic='true' in application tag to allow unencrypted HTTP traffic"
      • addedInput schema / properties / workspaceDir / description
        Added value: +"Path to decompiled APK workspace root directory containing AndroidManifest.xml (modified in-place)"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "addedActivities": {
        +      "description": "Activity class names added during the patch.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "addedApplicationMetadata": {
        +      "description": "Application metadata keys added during the patch.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "applicationClass": {
        +      "description": "Application class after the patch.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "patchedPermissions": {
        +      "description": "Permissions added during the patch.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "usesCleartextTraffic": {
        +      "description": "Reported cleartext-traffic configuration request.",
        +      "type": "boolean"
        +    },
        +    "validation": {
        +      "additionalProperties": false,
        +      "description": "Post-patch manifest validation result.",
        +      "properties": {
        +        "messages": {
        +          "items": {
        +            "type": "string"
        +          },
        +          "type": "array"
        +        },
        +        "status": {
        +          "enum": [
        +            "ok",
        +            "warning",
        +            "error"
        +          ],
        +          "type": "string"
        +        }
        +      },
        +      "required": [
        +        "status",
        +        "messages"
        +      ],
        +      "type": "object"
        +    },
        +    "workspaceDir": {
        +      "description": "Mutated decoded APK workspace.",
        +      "type": "string"
        +    }
        +  },
        +  "required": [
        +    "workspaceDir",
        +    "patchedPermissions",
        +    "addedApplicationMetadata",
        +    "addedActivities",
        +    "applicationClass",
        +    "usesCleartextTraffic",
        +    "validation"
        +  ],
        +  "type": "object"
        +}
    • Addedquery_memory_graph
    • Changedrecompile_align_and_sign9 fields changed
      • addedInput schema / properties / keystoreConfig / description
        Added value: +"Optional signing keystore configuration. If omitted, an auto-generated debug keystore is used"
      • addedInput schema / properties / keystoreConfig / properties / cn / description
        Added value: +"Common Name (CN) owner string for self-signed debug certificate"
      • addedInput schema / properties / keystoreConfig / properties / keyAlias / description
        Added value: +"Private key alias name inside signing keystore"
      • addedInput schema / properties / keystoreConfig / properties / keyPass / description
        Added value: +"Password for specific private key alias"
      • addedInput schema / properties / keystoreConfig / properties / keystorePass / description
        Added value: +"Keystore password for signing keystore access"
      • addedInput schema / properties / keystoreConfig / properties / keystorePath / description
        Added value: +"Path to custom JKS/PKCS12 signing keystore file (auto-generates debug keystore if omitted)"
      • addedInput schema / properties / outputApkPath / description
        Added value: +"Destination file path for final recompiled, 4-byte aligned, and cryptographically signed APK"
      • addedInput schema / properties / workspaceDir / description
        Added value: +"Path to decompiled APK workspace root directory containing modified Smali, assets, and AndroidManifest.xml"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "aligned": {
        +      "description": "Whether zipalign completed successfully.",
        +      "type": "boolean"
        +    },
        +    "keystorePath": {
        +      "description": "Keystore used for signing, when available.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "outputApkPath": {
        +      "description": "Absolute path to the signed output APK.",
        +      "type": "string"
        +    },
        +    "signingScheme": {
        +      "description": "Detected APK signature schemes.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "sizeBytes": {
        +      "description": "Final APK byte size.",
        +      "minimum": 0,
        +      "type": "integer"
        +    },
        +    "verified": {
        +      "description": "Whether apksigner verification completed successfully.",
        +      "type": "boolean"
        +    }
        +  },
        +  "required": [
        +    "outputApkPath",
        +    "signingScheme",
        +    "keystorePath",
        +    "aligned",
        +    "verified",
        +    "sizeBytes"
        +  ],
        +  "type": "object"
        +}
    • Changedsynthesize_flutter_payload6 fields changed
      • addedInput schema / properties / buildMode / description
        Added value: +"Flutter build mode target: 'release' (AOT production build), 'profile' (AOT performance build), 'debug' (JIT build)"
      • addedInput schema / properties / flutterProjectPath / description
        Added value: +"Path to source Flutter project root containing pubspec.yaml and lib/main.dart"
      • changedInput schema / properties / outputDir / description
        Previous value: -"Override payload output directory"New value: +"Optional custom directory path to write synthesized payload artifacts (defaults to system temp dir)"
      • addedInput schema / properties / targetAbis / description
        Added value: +"Target native CPU architectures to build payload binaries for (default: ['arm64-v8a', 'armeabi-v7a'])"
      • addedInput schema / properties / targetAbis / items / description
        Added value: +"Target Android Native ABI architecture (e.g. 'arm64-v8a' for modern 64-bit devices)"
      • changedOutput schema / (root)
        Previous value: -nullNew value: +{
        +  "$schema": "http://json-schema.org/draft-07/schema#",
        +  "additionalProperties": false,
        +  "properties": {
        +    "abis": {
        +      "description": "ABIs successfully emitted into the payload.",
        +      "items": {
        +        "enum": [
        +          "arm64-v8a",
        +          "armeabi-v7a",
        +          "x86",
        +          "x86_64"
        +        ],
        +        "type": "string"
        +      },
        +      "type": "array"
        +    },
        +    "appSizeBytes": {
        +      "anyOf": [
        +        {
        +          "minimum": 0,
        +          "type": "integer"
        +        },
        +        {
        +          "type": "null"
        +        }
        +      ],
        +      "description": "Extracted libapp.so size, when available."
        +    },
        +    "buildMode": {
        +      "description": "Flutter build mode used.",
        +      "enum": [
        +        "release",
        +        "profile",
        +        "debug"
        +      ],
        +      "type": "string"
        +    },
        +    "engineVersion": {
        +      "description": "Detected Flutter engine/version identifier, when available.",
        +      "type": [
        +        "string",
        +        "null"
        +      ]
        +    },
        +    "files": {
        +      "additionalProperties": {
        +        "items": {
        +          "type": "string"
        +        },
        +        "type": "array"
        +      },
        +      "description": "Payload-relative artifact paths grouped by type.",
        +      "type": "object"
        +    },
        +    "payloadDir": {
        +      "description": "Absolute directory containing synthesized payload artifacts.",
        +      "type": "string"
        +    },
        +    "warnings": {
        +      "description": "Build or artifact-completeness warnings.",
        +      "items": {
        +        "type": "string"
        +      },
        +      "type": "array"
        +    }
        +  },
        +  "required": [
        +    "payloadDir",
        +    "buildMode",
        +    "abis",
        +    "files",
        +    "engineVersion",
        +    "appSizeBytes",
        +    "warnings"
        +  ],
        +  "type": "object"
        +}
    • Addedupdate_agent_memory
  2. 6 tool updatesv0.1.2
    • First observedanalyze_injection_surface
    • First observeddecompile_apk
    • First observedinject_flutter_runtime_and_smali
    • First observedpatch_manifest_and_config
    • First observedrecompile_align_and_sign
    • First observedsynthesize_flutter_payload

TDQS

A4.1/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: the first six form a sequential APK injection pipeline, and the last three are agent memory operations. There is no overlap or ambiguity between any tools.

Naming Consistency5/5

All tool names use a consistent verb_noun snake_case pattern (e.g., decompile_apk, synthesize_flutter_payload, update_agent_memory). The naming convention is uniform throughout.

Tool Count4/5

The 9 tools are within a reasonable count, but the three memory-related tools are unrelated to the core APK injection purpose and make the set slightly over-scoped. A focused injector would have 6 tools.

Completeness5/5

The APK injection workflow is fully covered: decompile, analyze, synthesize payload, inject, patch manifest, and recompile/sign. There are no missing operations in the stated domain; the memory tools are extra but do not create gaps.

Maintenance

ActivityMaintained
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Provides a one-stop automated solution for Android APK security analysis by integrating tools like JEB, JADX, APKTOOL, FlowDroid, and MobSF into unified MCP standard API interfaces.
    11
    -
  • A
    license
    A
    quality
    F
    maintenance
    A real-time server that provides Flutter/Dart documentation and pub.dev package information to AI assistants, ensuring they generate accurate and up-to-date Flutter code.
    8
    73
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables analysis of native Android libraries (SO files) and Flutter applications, including decompilation, function identification, SSL certificate bypass patching, and binary modification through 30+ specialized tools.
    11
    -

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/MarwanDevSpace/mcp-flutter-apk-injector'

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