RESTCLIENT.NET / API REFERENCE
RestClient.Net.OpenApiGenerator.UrlParser
All API types · RestClient.Net.OpenApiGenerator · View source
public static partial class UrlParser
Parses base URLs and paths from OpenAPI documents.
Members
GetBaseUrlAndPath
public static Result<(string BaseUrl, string BasePath), string> GetBaseUrlAndPath(OpenApiDocument document, string? baseUrlOverride);
Gets the base URL and path from an OpenAPI document.
| Parameter | Type | Default | Description |
|---|---|---|---|
document |
OpenApiDocument |
Required | The OpenAPI document. |
baseUrlOverride |
string? |
Required | Optional base URL override. |
Returns: A result containing the base URL and path, or an error message.
View source: RestClient.Net.OpenApiGenerator/UrlParser.cs:16