Returns a paginated list of files in your workspace. Use offset and limit to paginate through results. See List endpoints for more information about pagination.
Omits files uploaded through the app and synced chat attachments — both are still retrievable by id. See File uploads for which document classes are listable versus retrievable-only.
Required scope: files:read
Rate limit category: Search
List files
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
fileListResponse, err := client.File.List(context.TODO(), githubcomlightfldlightfieldgo.FileListParams{
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", fileListResponse.Data)
}
{
"data": [
{
"id": "id",
"completedAt": "completedAt",
"createdAt": "createdAt",
"expiresAt": "expiresAt",
"filename": "filename",
"mimeType": "mimeType",
"sizeBytes": -9007199254740991,
"status": "PENDING"
}
],
"object": "object",
"totalCount": 0
}Returns Examples
{
"data": [
{
"id": "id",
"completedAt": "completedAt",
"createdAt": "createdAt",
"expiresAt": "expiresAt",
"filename": "filename",
"mimeType": "mimeType",
"sizeBytes": -9007199254740991,
"status": "PENDING"
}
],
"object": "object",
"totalCount": 0
}