Skip to main content

Examples

This section provides practical examples of using Dochia CLI for different API testing scenarios. Each example demonstrates real-world usage patterns and best practices.

Available Examples

Basic REST API Testing

Learn the fundamentals of API testing with Dochia using a simple REST API. This example covers:

  • Basic test execution
  • Understanding test results
  • Common configuration options

E-commerce API Testing

Comprehensive testing of an e-commerce API with complex business logic. This example demonstrates:

  • Testing multiple endpoints
  • Using reference data for realistic scenarios
  • Advanced configuration options
  • Custom headers and query parameters

Authentication Flows

Testing APIs with various authentication mechanisms. This example covers:

  • Bearer token authentication
  • API key authentication
  • OAuth flows
  • Session-based authentication

Using Reference Data

Advanced testing with external reference data for realistic test scenarios. This example shows:

  • Loading reference data from files
  • Using reference data in tests
  • Managing test data dependencies
  • Creating realistic test scenarios

Getting Started

If you're new to Dochia, we recommend starting with the Basic REST API Testing example and then progressing through the more advanced scenarios.

Each example includes:

  • Setup instructions - How to prepare the test environment
  • Command examples - Complete CLI commands you can copy and run
  • Expected results - What to expect from the test execution
  • Troubleshooting - Common issues and solutions

Next Steps

After working through these examples:

  1. Explore Playbooks - Learn about different testing strategies
  2. Advanced Configuration - Customize Dochia for your needs
  3. CLI Reference - Complete command documentation
  4. Enterprise Deployment - Scale for production use

Need Help?

If you encounter issues with any examples: