Function validateAgentExport

  • Validates an export config object without importing it.

    Checks structural correctness: schema version, required fields, type discriminator, and agency-specific field consistency. Does NOT validate the semantic correctness of the config (e.g. whether the model exists).

    Parameters

    Returns {
        valid: boolean;
        errors: string[];
    }

    Object with valid boolean and an array of error messages.

    • valid: boolean
    • errors: string[]

    Example

    const result = validateAgentExport(someObject);
    if (!result.valid) {
    console.error('Validation errors:', result.errors);
    }