networking

package
v0.6.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	HeaderKeyContinuationToken = "X-MS-ContinuationToken"

	ApiVersion70         = "7.0"
	ApiVersion70Preview1 = "7.0-preview.1"
	ApiVersion71Preview1 = "7.1-preview.1"
)

Variables

This section is empty.

Functions

func DeleteJSON added in v0.4.0

func DeleteJSON[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, apiVersion string) (*T, *http.Response, error)

func GetJSON added in v0.4.0

func GetJSON[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, apiVersion string) (*T, *http.Response, error)

func PatchJSON added in v0.4.0

func PatchJSON[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, body any, apiVersion string) (*T, *http.Response, error)

func PatchJSONSpecialContentType added in v0.4.0

func PatchJSONSpecialContentType[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, body any, apiVersion string) (*T, *http.Response, error)

func PostJSON added in v0.4.0

func PostJSON[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, body any, apiVersion string) (*T, *http.Response, error)

func PutJSON added in v0.4.0

func PutJSON[T any](c *RestClient, ctx context.Context, pathSegments []string, queryParams url.Values, body any, apiVersion string) (*T, *http.Response, error)

Types

type ImproperError

type ImproperError struct {
	Message *string `json:"Message,omitempty"`
}

type NoJSON added in v0.4.0

type NoJSON string

type RestClient

type RestClient struct {
	// contains filtered or unexported fields
}

func NewRestClient

func NewRestClient(baseUrl string, authorization string, providerVersion string) *RestClient

type WrappedError

type WrappedError struct {
	ExceptionId      *string                 `json:"$id,omitempty"`
	InnerError       *WrappedError           `json:"innerException,omitempty"`
	Message          *string                 `json:"message,omitempty"`
	TypeName         *string                 `json:"typeName,omitempty"`
	TypeKey          *string                 `json:"typeKey,omitempty"`
	ErrorCode        *int                    `json:"errorCode,omitempty"`
	EventId          *int                    `json:"eventId,omitempty"`
	CustomProperties *map[string]interface{} `json:"customProperties,omitempty"`
	StatusCode       *int
}

func (WrappedError) Error

func (e WrappedError) Error() string

type WrappedImproperError

type WrappedImproperError struct {
	Count *int           `json:"count,omitempty"`
	Value *ImproperError `json:"value,omitempty"`
}

Jump to

Keyboard shortcuts

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