argus-sdk-demo
v1.0.1
Published
Simple demo application for Argus SDK
Readme
Argus SDK Demo
A simple demonstration application for the Argus SDK that evaluates preset transactions against your financial control policies.
Quick Start
Install dependencies:
npm installSet up your API key:
# Copy the example environment file cp .env.example .env # Edit .env and add your API key # ARGUS_API_KEY=argus_your_actual_key_hereRun the demo:
npm start
Usage Options
Using Environment Variables
# Set in .env file or export directly
export ARGUS_API_KEY=argus_your_key_here
npm startUsing Command Line Arguments
# Specify API key
npm start -- --api-key argus_your_key_here
# Use custom API endpoint
npm start -- --api-key argus_your_key_here --base-url http://localhost:8000
# Run multiple iterations (useful for load testing)
npm start -- --api-key argus_your_key_here --iterations 5Command Line Options
--api-key, -k: Your Argus API key--base-url, -u: API base URL (default: http://localhost:8000)--iterations, -i: Number of times to run all transactions (default: 1)
What It Does
The demo runs 5 preset transactions with different characteristics:
- Morning Coffee - Small everyday purchase ($4.50)
- Grocery Shopping - Regular purchase ($127.83)
- Laptop Purchase - High-value electronics ($2,499.99)
- Luxury Car Down Payment - Very high amount wire transfer ($25,000)
- European Hotel Booking - Foreign currency transaction (€350)
Each transaction is evaluated against your active policy, and you'll see:
- Decision outcome (Approved/Rejected/Manual Review)
- Decision ID for tracking
- Failed rule (if rejected)
- Response time
Expected Results
Results will vary based on your policy configuration, but typically:
- Small purchases are approved
- Very large amounts may trigger manual review or rejection
- Different payment methods may have different limits
Viewing Results in Frontend
After running the demo, you can:
- Open your Argus frontend dashboard
- Navigate to the Transactions page to see all evaluated transactions
- Check the Dashboard for updated metrics and charts
- Review which rules were triggered in the transaction details
Development
To modify the demo or add more test scenarios, edit src/index.ts and add new transactions to the transactions array.
// Run in development mode with TypeScript
npm run dev