DeleteHostAuthenticationToken
client.Runners.Configurations.HostAuthenticationTokens.Delete(ctx, body) (*RunnerConfigurationHostAuthenticationTokenDeleteResponse, error)
POST/gitpod.v1.RunnerConfigurationService/DeleteHostAuthenticationToken
Deletes a host authentication token.
Use this method to:
- Remove unused tokens
- Revoke access
- Clean up expired tokens
Examples
-
Delete token:
Permanently removes a token.
id: "d2c94c27-3b76-4a42-b88c-95a85e392c68"
DeleteHostAuthenticationToken
package main
import (
"context"
"fmt"
"github.com/gitpod-io/gitpod-sdk-go"
"github.com/gitpod-io/gitpod-sdk-go/option"
)
func main() {
client := gitpod.NewClient(
option.WithBearerToken("My Bearer Token"),
)
hostAuthenticationToken, err := client.Runners.Configurations.HostAuthenticationTokens.Delete(context.TODO(), gitpod.RunnerConfigurationHostAuthenticationTokenDeleteParams{
ID: gitpod.F("d2c94c27-3b76-4a42-b88c-95a85e392c68"),
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", hostAuthenticationToken)
}
{}Returns Examples
{}