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
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,6 @@ public ErrorResponse(
public ErrorResponse()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -102,5 +102,6 @@ public IndexRepositoryRequest(
public IndexRepositoryRequest()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,6 @@ public IndexRepositoryResponse(
public IndexRepositoryResponse()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -75,5 +75,6 @@ public QueryMessage(
public QueryMessage()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -94,5 +94,6 @@ public QueryRequest(
public QueryRequest()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,6 @@ public QueryResponse(
public QueryResponse()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -148,5 +148,6 @@ public RepositoryInfo(
public RepositoryInfo()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -76,5 +76,6 @@ public RepositoryRef(
public RepositoryRef()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,6 @@ public SearchRequest(
public SearchRequest()
{
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,6 @@ public SearchResponse(
public SearchResponse()
{
}

}
}
1 change: 1 addition & 0 deletions src/libs/Greptile/Generated/Greptile.Models.Source.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -139,5 +139,6 @@ public Source(
public Source()
{
}

}
}
27 changes: 26 additions & 1 deletion src/libs/Greptile/Generated/Greptile.OptionsSupport.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,24 @@ public sealed class AutoSDKAuthorizationProviderHook : global::Greptile.AutoSDKH
{
context = context ?? throw new global::System.ArgumentNullException(nameof(context));

if (context.Request == null)
{
return;
}

var perRequest = context.RequestOptions?.Authorizations;
if (perRequest != null && perRequest.Count > 0)
{
for (var index = 0; index < perRequest.Count; index++)
{
ApplyAuthorization(context.Request, perRequest[index]);
}

return;
}

var provider = context.ClientOptions?.AuthorizationProvider;
if (provider == null || context.Request == null)
if (provider == null)
{
return;
}
Expand Down Expand Up @@ -237,6 +253,15 @@ public sealed class AutoSDKRequestOptions
/// Overrides response buffering for this request when set.
/// </summary>
public bool? ReadResponseAsString { get; set; }

/// <summary>
/// Optional per-request authorization values. When non-empty, the built-in
/// <see cref="AutoSDKAuthorizationProviderHook"/> applies these instead of consulting
/// <see cref="AutoSDKClientOptions.AuthorizationProvider"/> for this request only.
/// Useful for multi-tenant routing or "act-as" admin tooling that needs a different
/// credential per call without mutating shared client state.
/// </summary>
public global::System.Collections.Generic.IReadOnlyList<global::Greptile.AutoSDKAuthorizationValue>? Authorizations { get; set; }
}

/// <summary>
Expand Down