## List rubrics

`client.Rubrics.List(ctx, query) (*CursorPage[RubricResponse], error)`

**get** `/v5/rubrics`

List the current account's rubrics, paginated.

Only the latest version of each rubric is returned, and archived rubrics are
excluded (this endpoint has no option to include them). The optional `title`
filter matches as a case-insensitive substring, and the optional `tags` filter
narrows results to rubrics carrying the given tags. Each returned rubric
carries only a slim criteria summary (title and weight per criterion) rather
than full criteria; use the get-rubric endpoint to retrieve full criteria
detail.

### Parameters

- `query RubricListParams`

  - `EndingBefore param.Field[string]`

  - `Limit param.Field[int64]`

  - `SortBy param.Field[string]`

  - `SortOrder param.Field[SortOrder]`

  - `StartingAfter param.Field[string]`

  - `Tags param.Field[[]string]`

    Filter by tags

  - `Title param.Field[string]`

    Filter by title (case-insensitive)

### Returns

- `type RubricResponse struct{…}`

  - `ID string`

  - `CreatedAt Time`

  - `CreatedBy Identity`

    The identity that created the entity.

    - `ID string`

    - `Type IdentityType`

      - `const IdentityTypeUser IdentityType = "user"`

      - `const IdentityTypeServiceAccount IdentityType = "service_account"`

    - `Object IdentityObject`

      - `const IdentityObjectIdentity IdentityObject = "identity"`

  - `Tags []string`

    The tags associated with the entity

  - `Title string`

  - `Version int64`

  - `ArchivedAt Time`

  - `Criteria []RubricResponseCriterionUnion`

    Full criteria on get, summary (title + weight) on list

    - `type RubricCriteriaResponse struct{…}`

      - `ID string`

      - `CreatedAt Time`

      - `RubricID string`

      - `Title string`

      - `Version int64`

      - `Annotations map[string, any]`

      - `Object RubricCriteriaResponseObject`

        - `const RubricCriteriaResponseObjectRubricCriteria RubricCriteriaResponseObject = "rubric_criteria"`

      - `Weight float64`

    - `type RubricCriteriaSummaryResponse struct{…}`

      Slim criteria projection for list endpoints (title + weight only).

      - `Title string`

      - `Weight float64`

  - `Object RubricResponseObject`

    - `const RubricResponseObjectRubric RubricResponseObject = "rubric"`

  - `UpdatedAt Time`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  page, err := client.Rubrics.List(context.TODO(), sgpdev.RubricListParams{

  })
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", page)
}
```

#### Response

```json
{
  "has_more": true,
  "items": [
    {
      "id": "id",
      "created_at": "2019-12-27T18:11:19.117Z",
      "created_by": {
        "id": "id",
        "type": "user",
        "object": "identity"
      },
      "tags": [
        "string"
      ],
      "title": "title",
      "version": 0,
      "archived_at": "2019-12-27T18:11:19.117Z",
      "criteria": [
        {
          "id": "id",
          "created_at": "2019-12-27T18:11:19.117Z",
          "rubric_id": "rubric_id",
          "title": "title",
          "version": 0,
          "annotations": {
            "foo": "bar"
          },
          "object": "rubric_criteria",
          "weight": 0
        }
      ],
      "object": "rubric",
      "updated_at": "2019-12-27T18:11:19.117Z"
    }
  ],
  "total": 0,
  "limit": 0,
  "object": "list"
}
```
