Cogny CLI · Email

    Rule queried from the terminal.

    List subscribers, tags, segments and campaigns, pull per-campaign statistics, tag and update subscribers, and fire transactional sends — from Bash over the Rule MCP. The Rule API without the boilerplate.

    # 1. sign up (free for 15 calls) — uses your git email
    $ npx @cogny/cli init --agent claude-code
    
    # 2. see every Rule tool
    $ cogny tools list
    
    # 3. call any tool from Bash — no MCP wiring
    $ cogny tools call mcp__Rule__tool_get_campaign_statistics --input '{…}'
    ❯ start Cogny Solo — $9/mo@cogny/cli on npm →

    cogny --who

    TWO PATHS
    You're a human

    Today you click into each Rule campaign to read its stats and manage tags one subscriber at a time. With the CLI you pull campaign statistics as JSON and bulk-tag subscribers in a single scripted call. Connect Rule once in Cogny Solo and let your coding agent — or scheduled reports — do the querying for you.

    ❯ start Solo
    You're an agent

    Self-onboard with one command. The CLI issues a key, wires nothing, and exposes every Rule tool over JSON-RPC. First 15 calls are free.

    $ npx @cogny/cli init --agent claude-code

    cogny tools call

    3 EXAMPLES

    Real tool names from the Rule MCP. Send --input JSON, get JSON back.

    mcp__Rule__tool_get_campaign_statisticsOpen/click/bounce stats for one campaign.
    $ cogny tools call mcp__Rule__tool_get_campaign_statistics \
      --input '{"campaign_id":50231}'
    example response
    {
      "campaign_id": 50231,
      "sent": 12040,
      "delivered": 11902,
      "opens": 4810,
      "clicks": 922,
      "bounces": 138,
      "unsubscribes": 34
    }
    mcp__Rule__tool_list_campaignsList campaigns, optionally filtered by status.
    $ cogny tools call mcp__Rule__tool_list_campaigns \
      --input '{"limit":2,"status":"sent"}'
    example response
    {
      "campaigns": [
        {
          "id": 50231,
          "subject": "June newsletter",
          "status": "sent",
          "message_type": "campaign",
          "sent": 12040
        },
        {
          "id": 50118,
          "subject": "Flash sale",
          "status": "sent",
          "message_type": "campaign",
          "sent": 11540
        }
      ]
    }
    mcp__Rule__tool_add_subscriber_tagsAdd tags to a subscriber.
    $ cogny tools call mcp__Rule__tool_add_subscriber_tags \
      --input '{"identifier":"880142","tags":["vip","q2-buyer"]}'
    example response
    {
      "identifier": "880142",
      "tags": [
        "vip",
        "q2-buyer"
      ],
      "status": "success"
    }

    cogny tools list

    MORE

    A sample of the rest of the Rule surface. Run cogny tools list --json for every tool and its input schema.

    mcp__Rule__tool_list_subscribersmcp__Rule__tool_create_subscribermcp__Rule__tool_update_subscribermcp__Rule__tool_list_tagsmcp__Rule__tool_list_segmentsmcp__Rule__tool_get_campaignmcp__Rule__tool_schedule_campaignmcp__Rule__tool_send_transaction

    cogny --faq

    Is this an official Rule CLI?

    No — it is the Cogny CLI calling the Rule MCP over the cogny-mcp-proxy. You connect Rule once in Cogny with your API token, and then every tool is callable from Bash with your Cogny key.

    Can it send transactional email?

    Yes. `tool_send_transaction` fires a transactional send, alongside campaign tools (list, get, schedule, send) and subscriber/tag management. It is the same Rule API surface, scriptable.

    Can my coding agent use this without MCP setup?

    Yes — that is the point. `npx @cogny/cli init --agent claude-code` issues a key, then `cogny tools call mcp__Rule__tool_get_campaign_statistics --input ...` works from any shell. No /mcp wiring or restart needed.

    related CLIs

    /cli/get-a-newsletter/cli/mailerlite/cli/symplify/cli/brevo

    Building an agent? The full tool map for all servers is one fetch: /cli/llms.txt