godo.BatchInference.ListJobs()

Generated on 5 Nov 2026 from godo version v1.236.0

Usage

client.BatchInference.ListJobs(ctx context.Context, opts *godo.ListBatchesOptions) (*godo.ListBatchesResponse, *godo.Response, error)

Description

ListJobs returns a list of batch inference jobs with optional filtering and pagination.

This method sends a GET request to /v1/batches.

Parameters

opts *godo.ListBatchesOptions

Fields of godo.ListBatchesOptions

ListBatchesOptions specifies optional query parameters for listing batch jobs.

After string
Limit int
Status string

Returns

*godo.ListBatchesResponse
*godo.Response

The HTTP response, with pagination Links, Meta, and Rate limit information.

error

Non-nil when the request fails. API errors are returned as *godo.ErrorResponse.

Fields of godo.ListBatchesResponse

ListBatchesResponse is returned by GET /v1/batches. Uses Relay-style cursor pagination.

Edges []godo.BatchEdge

JSON key: edges

PageInfo godo.BatchPageInfo

JSON key: page_info

Request Sample

Show Request Sample
package main

import (
	"context"
	"fmt"
	"log"
	"os"

	"github.com/digitalocean/godo"
)

func main() {
	client := godo.NewFromToken(os.Getenv("DIGITALOCEAN_TOKEN"))
	ctx := context.TODO()

	result, _, err := client.BatchInference.ListJobs(ctx, &godo.ListBatchesOptions{
		After: "<your-after>",
		Limit: 1234567,
		Status: "<your-status>",
	})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", result)
}

More Information

See GET /v1/batches in the API reference for additional detail on responses, headers, parameters, and more.

See the Go package documentation for the source of this method.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.