Skip to content

assafbar2/fcli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fcli

A CLI for Intercom and FIN — test AI responses, check urgent tickets, and view conversation stats from your terminal.


Setup

1. Authentication (required)

fcli requires an Intercom API token. No token = no commands will run.

export INTERCOM_TOKEN=your_token_here

Get your token at: https://app.intercom.com/a/apps/_/settings/api-keys

Add the export to your shell profile (~/.zshrc, ~/.bashrc) to persist it.

2. Install

go install github.com/assafbarnir/fcli@latest

Or build from source:

git clone https://github.com/assafbarnir/fcli
cd fcli
go build -o fcli .

Commands

fcli test "<message>"

Send a message to FIN and see its response.

fcli test "how do I reset my password?"
fcli test "what are your pricing plans?" --json

FIN uses a test contact to reply. Set INTERCOM_TEST_EMAIL to control which contact is used (default: fcli-test@fcli.test).


fcli tickets

List all urgent open tickets with contact, subject, assignee, and age.

fcli tickets
fcli tickets --json | jq '.[0]'

Fetches up to 200 conversations.

Note: The subject field is sourced from Source.Body which may contain HTML tags in some workspace configurations.


fcli stats

Show FIN AI conversation volume for the past 24 hours, broken down by hour.

fcli stats
fcli stats --json | jq '.hourly'

Flags

Flag Description
--json Output as JSON instead of pretty tables. Works on all commands.
--help Show help for any command.

Environment Variables

Variable Required Default Description
INTERCOM_TOKEN Yes Your Intercom API token
INTERCOM_TEST_EMAIL No fcli-test@fcli.test Contact email used by fcli test

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages