HTTP Archive

Provides classes for parsing HTTP Archive (*.har) files

Technology

The har module provides comprehensive HTTP Archive (HAR) file parsing and management capabilities for Project Forge applications. HAR files are standard JSON-formatted archives that capture detailed information about HTTP transactions, making them invaluable for debugging, performance analysis, and API documentation.

Overview

This module enables applications to:

Key Features

File Management

Data Analysis

Integration

Package Structure

Core Library

Utilities

Web Interface

Usage Examples

Loading HAR Files

 1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Create service with file system backend
service := har.NewService(fs)

// Load a HAR file
log, err := service.Load("example.har")
if err != nil {
return err
}

// Access entries
for _, entry := range log.Entries {
fmt.Printf("Request: %s %s\n", entry.Request.Method, entry.Request.URL)
fmt.Printf("Response: %d\n", entry.Response.Status)
}

Web API Endpoints

Search Integration

The module integrates with Project Forge’s search system to find HAR files and entries matching specific criteria.

Configuration

No additional configuration required beyond standard Project Forge setup. HAR files are stored in the ./har directory relative to the application root.

File Format Support

Supports the full HAR 1.2 specification:

Source Code

See Also