Skip to content

Latest commit

 

History

History
55 lines (42 loc) · 1.9 KB

README.md

File metadata and controls

55 lines (42 loc) · 1.9 KB

Characters

(Characters)

Available Operations

GetCharacterBase

Returns character base record

Example Usage

package main

import(
	"github.com/dashotv/tvdb/openapi/models/shared"
	"github.com/dashotv/tvdb/openapi"
	"context"
	"log"
)

func main() {
    s := openapi.New(
        openapi.WithSecurity(shared.Security{
            BearerAuth: "<YOUR_BEARER_TOKEN_HERE>",
        }),
    )
    var id float64 = 1956.5
    ctx := context.Background()
    res, err := s.Characters.GetCharacterBase(ctx, id)
    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.
id float64 ✔️ id

Response

*operations.GetCharacterBaseResponse, error

Error Object Status Code Content Type
sdkerrors.SDKError 4xx-5xx /