Skip to content

Latest commit

 

History

History
59 lines (44 loc) · 2.58 KB

README.md

File metadata and controls

59 lines (44 loc) · 2.58 KB

Liveness

(Liveness)

Available Operations

V1Liveness

Example Usage

package main

import(
	unkeygo "github.com/unkeyed/unkey-go"
	"context"
	"log"
)

func main() {
    s := unkeygo.New(
        unkeygo.WithSecurity("<YOUR_BEARER_TOKEN_HERE>"),
    )

    ctx := context.Background()
    res, err := s.Liveness.V1Liveness(ctx)
    if err != nil {
        log.Fatal(err)
    }
    if res.Object != nil {
        // handle response
    }
}

Parameters

Parameter Type Required Description
ctx context.Context ✔️ The context to use for the request.
opts []operations.Option The options for this request.

Response

*operations.V1LivenessResponse, error

Error Object Status Code Content Type
sdkerrors.ErrBadRequest 400 application/json
sdkerrors.ErrUnauthorized 401 application/json
sdkerrors.ErrForbidden 403 application/json
sdkerrors.ErrNotFound 404 application/json
sdkerrors.ErrConflict 409 application/json
sdkerrors.ErrTooManyRequests 429 application/json
sdkerrors.ErrInternalServerError 500 application/json
sdkerrors.SDKError 4xx-5xx /