Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,245 changes: 623 additions & 622 deletions generated/anthropic.zig

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions generated/generated_v2.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:54 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:59 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down Expand Up @@ -48,7 +49,7 @@ pub const Order = struct {
};

pub const ApiResponse = struct {
@"type": ?[]const u8 = null,
type: ?[]const u8 = null,
message: ?[]const u8 = null,
code: ?i64 = null,
};
Expand Down
5 changes: 3 additions & 2 deletions generated/generated_v2_yaml.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:55 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:46:01 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand All @@ -23,7 +24,7 @@ pub const Pet = struct {
};

pub const ApiResponse = struct {
@"type": ?[]const u8 = null,
type: ?[]const u8 = null,
message: ?[]const u8 = null,
code: ?i64 = null,
};
Expand Down
5 changes: 3 additions & 2 deletions generated/generated_v3.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:55 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:58 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down Expand Up @@ -61,7 +62,7 @@ pub const User = struct {
};

pub const ApiResponse = struct {
@"type": ?[]const u8 = null,
type: ?[]const u8 = null,
message: ?[]const u8 = null,
code: ?i64 = null,
};
Expand Down
3 changes: 2 additions & 1 deletion generated/generated_v31.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:55 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:59 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down
3 changes: 2 additions & 1 deletion generated/generated_v31_yaml.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:54 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:59 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down
5 changes: 3 additions & 2 deletions generated/generated_v32.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:54 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:59 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down Expand Up @@ -48,7 +49,7 @@ pub const Order = struct {
};

pub const ApiResponse = struct {
@"type": ?[]const u8 = null,
type: ?[]const u8 = null,
message: ?[]const u8 = null,
code: ?i64 = null,
};
Expand Down
5 changes: 3 additions & 2 deletions generated/generated_v3_yaml.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:54 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:46:00 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand Down Expand Up @@ -61,7 +62,7 @@ pub const User = struct {
};

pub const ApiResponse = struct {
@"type": ?[]const u8 = null,
type: ?[]const u8 = null,
message: ?[]const u8 = null,
code: ?i64 = null,
};
Expand Down
27 changes: 14 additions & 13 deletions generated/lmstudio.zig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// <auto-generated>
// this code was generated by openapi2zig 0.4.0 (653555e) on 2026-07-19 21:44:55 UTC
// this code was generated by openapi2zig 0.4.0 (ecbd8f7) on 2026-07-19 22:45:59 UTC
// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
// </auto-generated>

const std = @import("std");

///////////////////////////////////////////
Expand All @@ -21,7 +22,7 @@ pub const UnloadModelRequest = struct {
};

pub const ReasoningOutput = struct {
@"type": []const u8,
type: []const u8,
content: []const u8,
};

Expand Down Expand Up @@ -84,7 +85,7 @@ pub const LoadedInstance = struct {
};

pub const TextInput = struct {
@"type": []const u8,
type: []const u8,
content: []const u8,
};

Expand Down Expand Up @@ -129,7 +130,7 @@ pub const ModelInfo = struct {
loaded_instances: []const LoadedInstance,
quantization: ?ModelInfoQuantization = null,
description: ?[]const u8 = null,
@"type": []const u8,
type: []const u8,
};

pub const EmbeddingLoadConfig = struct {
Expand All @@ -150,7 +151,7 @@ pub const DownloadStatusResponse = struct {
pub const PluginIntegration = struct {
allowed_tools: ?[]const []const u8 = null,
id: []const u8,
@"type": []const u8,
type: []const u8,
};

pub const ChatStats = struct {
Expand Down Expand Up @@ -258,7 +259,7 @@ pub const ChatRequest = struct {
};

pub const MessageOutput = struct {
@"type": []const u8,
type: []const u8,
content: []const u8,
};

Expand All @@ -273,7 +274,7 @@ pub const LoadedInstanceConfig = struct {

pub const ImageInput = struct {
data_url: []const u8,
@"type": []const u8,
type: []const u8,
};

pub const UnloadModelResponse = struct {
Expand All @@ -283,14 +284,14 @@ pub const UnloadModelResponse = struct {
pub const InvalidToolCallOutputMetadata = struct {
arguments: ?std.json.Value = null,
tool_name: []const u8,
@"type": []const u8,
type: []const u8,
provider_info: ?ProviderInfo = null,
};

pub const InvalidToolCallOutput = struct {
metadata: InvalidToolCallOutputMetadata,
reason: []const u8,
@"type": []const u8,
type: []const u8,
};

pub const LoadModelResponseLoadConfig = union(enum) {
Expand Down Expand Up @@ -325,11 +326,11 @@ pub const LoadModelResponse = struct {
status: []const u8,
instance_id: []const u8,
load_config: ?LoadModelResponseLoadConfig = null,
@"type": []const u8,
type: []const u8,
};

pub const ProviderInfo = struct {
@"type": []const u8,
type: []const u8,
plugin_id: ?[]const u8 = null,
server_label: ?[]const u8 = null,
};
Expand Down Expand Up @@ -368,7 +369,7 @@ pub const ChatInputItem = union(enum) {
pub const EphemeralMcpIntegration = struct {
server_url: []const u8,
allowed_tools: ?[]const []const u8 = null,
@"type": []const u8,
type: []const u8,
headers: ?std.json.Value = null,
server_label: []const u8,
};
Expand All @@ -377,7 +378,7 @@ pub const ToolCallOutput = struct {
arguments: std.json.Value,
tool: []const u8,
output: []const u8,
@"type": []const u8,
type: []const u8,
provider_info: ProviderInfo,
};

Expand Down
1 change: 1 addition & 0 deletions src/generators/generated_header.zig
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ pub fn render(allocator: std.mem.Allocator, version: []const u8, timestamp: []co
\\// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
\\// </auto-generated>
\\
\\
, .{ version, timestamp });
}

Expand Down
16 changes: 8 additions & 8 deletions src/generators/unified/ident_utils.zig
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ pub fn isIdentContinue(c: u8) bool {

pub fn isReservedIdent(name: []const u8) bool {
const reserved = [_][]const u8{
"addrspace", "align", "allowzero", "and", "anyerror", "anyframe", "anyopaque", "anytype",
"asm", "async", "await", "bool", "break", "callconv", "catch", "comptime",
"const", "continue", "defer", "else", "enum", "errdefer", "error", "export",
"extern", "false", "fn", "for", "if", "inline", "isize", "linksection",
"noalias", "noreturn", "nosuspend", "null", "opaque", "or", "orelse", "packed",
"pub", "resume", "return", "struct", "suspend", "switch", "test", "threadlocal",
"true", "try", "type", "undefined", "union", "unreachable", "usize", "usingnamespace",
"var", "void", "volatile", "while",
"addrspace", "align", "allowzero", "and", "anyerror", "anyframe", "anyopaque", "anytype",
"asm", "async", "await", "bool", "break", "callconv", "catch", "comptime",
"const", "continue", "defer", "else", "enum", "errdefer", "error", "export",
"extern", "false", "fn", "for", "if", "inline", "isize", "linksection",
"noalias", "noreturn", "nosuspend", "null", "opaque", "or", "orelse", "packed",
"pub", "resume", "return", "struct", "suspend", "switch", "test", "threadlocal",
"true", "try", "undefined", "union", "unreachable", "usize", "usingnamespace", "var",
"void", "volatile", "while",
};
for (reserved) |word| {
if (std.mem.eql(u8, name, word)) return true;
Expand Down
1 change: 1 addition & 0 deletions src/tests/generated_header_tests.zig
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ test "render emits expected header" {
\\// changes to this file may cause incorrect behavior and will be lost if the code is regenerated
\\// </auto-generated>
\\
\\
, header);
}

Expand Down
Loading