generic_client

package
v0.29.2-alpha Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2025 License: MPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetHTTPRetryDelay

func GetHTTPRetryDelay(errorInfo *HTTPGraphError, attempt int) time.Duration

GetHTTPRetryDelay calculates the appropriate retry delay - mirrors SDK logic

func HandleHTTPGraphError

func HandleHTTPGraphError(ctx context.Context, httpResp *http.Response, resp interface{}, operation string, requiredPermissions []string)

HandleHTTPGraphError processes HTTP Graph API errors - exact replica of HandleKiotaGraphError

Types

type HTTPGraphError

type HTTPGraphError struct {
	StatusCode      int
	ErrorCode       string
	ErrorMessage    string
	Target          string
	IsODataError    bool
	AdditionalData  map[string]interface{}
	Headers         map[string][]string
	RequestDetails  string
	RetryAfter      string
	RequestID       string
	ClientRequestID string
	ErrorDate       string
	InnerErrors     []errors.InnerErrorInfo
	ErrorDetails    []errors.ErrorDetailInfo
	CorrelationID   string
	ThrottledReason string
	Category        errors.ErrorCategory
	DiagnosticInfo  string
	ResponseBody    string
}

HTTPGraphError represents a comprehensive Graph API error extracted from HTTP responses This mirrors the errors.GraphErrorInfo structure but for raw HTTP calls

func ExtractHTTPGraphError

func ExtractHTTPGraphError(ctx context.Context, httpResp *http.Response) *HTTPGraphError

ExtractHTTPGraphError extracts and analyzes error information from HTTP Graph API responses This is an exact replica of errors.GraphError but for raw HTTP calls

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL