ListEditors
client.Editors.List(ctx, params) (*EditorsPage[Editor], error)
POST/gitpod.v1.EditorService/ListEditors
Lists all available code editors, optionally filtered to those allowed in an organization.
Use this method to:
- View supported editors
- Get editor capabilities
- Browse editor options
- Check editor availability
Examples
-
List editors:
Shows all available editors with pagination.
pagination: pageSize: 20 -
List editors available to the organization:
Shows all available editors that are allowed by the policies enforced in the organization with pagination.
pagination: pageSize: 20 filter: allowedByPolicy: true
ListEditors
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"),
)
page, err := client.Editors.List(context.TODO(), gitpod.EditorListParams{
Pagination: gitpod.F(gitpod.EditorListParamsPagination{
PageSize: gitpod.F(int64(20)),
}),
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", page)
}
{
"editors": [
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"installationInstructions": "installationInstructions",
"name": "name",
"urlTemplate": "urlTemplate",
"alias": "alias",
"iconUrl": "iconUrl",
"shortDescription": "shortDescription",
"versions": [
{
"version": "version"
}
]
}
],
"pagination": {
"nextToken": "nextToken"
}
}Returns Examples
{
"editors": [
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"installationInstructions": "installationInstructions",
"name": "name",
"urlTemplate": "urlTemplate",
"alias": "alias",
"iconUrl": "iconUrl",
"shortDescription": "shortDescription",
"versions": [
{
"version": "version"
}
]
}
],
"pagination": {
"nextToken": "nextToken"
}
}