Skip to content

Quick Start โ€‹

Get started with the cyber.trackr.live API in minutes! Choose your approach based on your needs.

Choose Your Workflow โ€‹

Install and Basic Usage โ€‹

First, install the Ruby client - it only takes a minute.

Complete Ruby Examples: See the Ruby Client guide for comprehensive examples including basic usage, workflows, and error handling patterns.

Common Workflow Patterns โ€‹

1. Discovery Workflow โ€‹

ruby
# Find STIGs for specific technology
stigs = helper.list_stigs
juniper_stigs = stigs.select { |id, info| info[:title].include?('Juniper') }

puts "๐Ÿ“ก Juniper STIGs found:"
juniper_stigs.each do |id, info|
  puts "  โ€ข #{info[:title]} (v#{info[:version]}.#{info[:release]})"
end

2. Compliance Analysis Workflow โ€‹

ruby
# Get complete STIG data
stig = helper.fetch_complete_stig('Juniper_SRX_Services_Gateway_ALG', '3', '3')

# Analyze requirement severity distribution
severity_counts = stig[:requirements].group_by { |req| req[:severity] }
                                     .transform_values(&:count)

puts "๐Ÿ“Š Severity Distribution:"
severity_counts.each { |severity, count| puts "  #{severity}: #{count}" }

# Find CAT I (high) requirements
cat1_requirements = stig[:requirements].select { |req| req[:severity] == 'high' }
puts "\n๐Ÿšจ Critical (CAT I) Requirements: #{cat1_requirements.count}"

3. Automation Integration Workflow โ€‹

ruby
# Extract check procedures for automation
stig[:requirements].each do |req|
  next unless req[:severity] == 'high'
  
  puts "\n๐Ÿ” #{req[:id]}: #{req[:title]}"
  puts "Check: #{req[:check_content]}"
  puts "Fix: #{req[:fix_text]}" if req[:fix_text]
end

๐ŸŒ Direct API Access โ€‹

Basic HTTP Requests โ€‹

bash
# List all documents
curl https://cyber.trackr.live/api/stig

# Get specific STIG metadata
curl https://cyber.trackr.live/api/stig/Juniper_SRX_Services_Gateway_ALG/3/3

# Get all requirements for a STIG
curl https://cyber.trackr.live/api/stig/Juniper_SRX_Services_Gateway_ALG/3/3/requirements

JavaScript/TypeScript Example โ€‹

javascript
// Modern fetch API
const response = await fetch('https://cyber.trackr.live/api/stig');
const stigs = await response.json();

console.log(`๐Ÿ“‹ Found ${Object.keys(stigs).length} documents`);

// Get specific STIG
const stig = await fetch(
  'https://cyber.trackr.live/api/stig/Juniper_SRX_Services_Gateway_ALG/3/3/requirements'
).then(r => r.json());

console.log(`๐Ÿ›ก๏ธ ${stig.title} has ${stig.requirements.length} requirements`);

Python Example โ€‹

python
import requests

# List STIGs
response = requests.get('https://cyber.trackr.live/api/stig')
stigs = response.json()
print(f"๐Ÿ“‹ Found {len(stigs)} documents")

# Get specific STIG
stig_response = requests.get(
    'https://cyber.trackr.live/api/stig/Juniper_SRX_Services_Gateway_ALG/3/3/requirements'
)
stig = stig_response.json()
print(f"๐Ÿ›ก๏ธ {stig['title']} has {len(stig['requirements'])} requirements")

๐Ÿ“š Interactive Documentation โ€‹

Zero setup required! Use our interactive API documentation:

  1. Visit API Reference - Complete endpoint documentation
  2. Click any endpoint - Detailed parameter descriptions
  3. Use "Try it out" - Make live API calls in your browser
  4. View responses - Real data with example structures

Best for:

  • ๐Ÿ” API exploration - Understand available data
  • ๐Ÿงช Quick testing - Validate endpoints before coding
  • ๐Ÿ“– Learning - See real request/response examples

๐Ÿ”ง Generate Your Own Client โ€‹

Use our OpenAPI 3.1.1 specification to generate clients in any language:

TypeScript/JavaScript โ€‹

bash
docker run --rm -v "${PWD}:/local" openapitools/openapi-generator-cli generate \
  -i https://raw.githubusercontent.com/mitre/cyber-trackr-live/main/openapi/openapi.yaml \
  -g typescript-fetch \
  -o ./cyber-trackr-client \
  --additional-properties=npmName=cyber-trackr-client

Python โ€‹

bash
docker run --rm -v "${PWD}:/local" openapitools/openapi-generator-cli generate \
  -i https://raw.githubusercontent.com/mitre/cyber-trackr-live/main/openapi/openapi.yaml \
  -g python \
  -o ./cyber-trackr-client \
  --additional-properties=packageName=cyber_trackr_client

Go โ€‹

bash
docker run --rm -v "${PWD}:/local" openapitools/openapi-generator-cli generate \
  -i https://raw.githubusercontent.com/mitre/cyber-trackr-live/main/openapi/openapi.yaml \
  -g go \
  -o ./cyber-trackr-client \
  --additional-properties=packageName=cybertrackr

Real-World Use Cases โ€‹

๐Ÿข Enterprise Compliance โ€‹

Enterprise Compliance Examples: See the Ruby Client examples for automated compliance dashboard patterns and technology stack STIG processing.

๐Ÿ”ง Security Tool Integration โ€‹

Security Tool Integration Examples: See the Ruby Client examples for automated check extraction and security scanning tool integration patterns.

Error Handling & Best Practices โ€‹

Robust Error Handling โ€‹

See the Ruby Client examples for comprehensive error handling patterns including API errors, timeouts, and retry logic.

Rate Limiting & Performance โ€‹

Performance Examples: See the Ruby Client examples for rate limiting, batch processing, and performance optimization patterns.

Next Steps โ€‹

๐ŸŽฏ For API Consumers โ€‹

๐Ÿ—๏ธ For Developers โ€‹

๐ŸŒ For Enterprise โ€‹

Questions? Check our GitHub Discussions or browse the complete documentation.

Released under the Apache-2.0 License.