Skip to content

CLI & MCP

Apiway’s Intent Engine provides two headless interfaces for API governance without the UI: a command-line tool and a Model Context Protocol (MCP) server for AI coding assistants.

Not every team wants a management portal. Some prefer:

  • CI/CD pipelines that validate and deploy APIs as part of the build
  • Developer workflows where API governance happens in the terminal
  • AI-assisted development where Claude Code or other AI tools manage APIs directly

The CLI and MCP server provide the same platform capabilities — no UI required.

The Apiway CLI lets you manage APIs from the command line:

Terminal window
# Upload and deploy an API
apiway deploy ./openapi.yaml --env production
# Check compliance
apiway compliance ./openapi.yaml
# Get recommendations
apiway recommend ./openapi.yaml
# List your APIs
apiway apis list
# Check subscription status
apiway subscriptions list --api payments-v1

Add Apiway to your deployment pipeline:

# Example: GitHub Actions
- name: Deploy API
run: |
apiway deploy ./api/openapi.yaml \
--env ${{ env.ENVIRONMENT }} \
--token ${{ secrets.APIWAY_TOKEN }}

Every API change goes through the same governance, compliance, and security checks — whether deployed from the CLI or the UI.

The MCP (Model Context Protocol) integration lets AI coding assistants interact with Apiway directly. Configure it as an MCP server in your AI tool.

With the MCP server configured, AI agents can:

  • Upload and validate OpenAPI specifications
  • Check compliance scores and get recommendations
  • Deploy APIs to environments
  • Create and manage subscriptions
  • Query metering and cost data
  • Monitor governance flow status
> Deploy my payments API to staging
I'll deploy your OpenAPI spec from ./api/payments.yaml
to the staging environment.
1. Validating specification... passed
2. Compliance check... score 94/100
3. Submitting to governance... auto-approved (staging)
4. Deploying to gateway... staging revision created
5. Activating... done
Your API is live at:
https://staging.gateway.apiway.net/payments-v1/

The AI agent uses the same platform APIs and follows the same governance rules as any other client.

Both the CLI and MCP server enable design-time governance — validating and improving APIs before they’re deployed:

  • Run compliance checks locally during development
  • Get design recommendations before committing
  • Catch governance issues in pull requests, not production

This is especially powerful for teams that want governance guardrails without a full platform deployment.