Skip to content

Catalog Attribute Families — Datagrid Listing

Paginated, filterable, and sortable attribute family list that mirrors the Bagisto admin Catalog → Attribute Families datagrid 1:1. This is the authoritative family-management listing for the admin API — same 3 columns and the same sort options used by the datagrid.

For how a family's attribute groups and attributes are structured, and the delete guards, see the Attribute Families overview.

Endpoint

EndpointMethodAuthentication
/api/admin/catalog/familiesGETAdmin Bearer token

Query Parameters

ParameterTypeDescriptionExample
pageintegerPage number (1-based, default 1)1
per_pageintegerItems per page (default 10, max 50)10
idstringFilter by family ID — single integer or comma-separated list (e.g. "1" or "1,2")1
codestringPartial family code match (SQL LIKE %value%)default
namestringPartial family name match (SQL LIKE %value%)Default
sortstringColumn to sort by (see Sorting section below)id
orderstringSort direction: asc or desc (default desc)desc

Response Shape

Responses use the standard admin { data, meta } envelope.

meta object

FieldTypeDescription
currentPageintegerCurrent page number (1-based)
perPageintegerNumber of items on this page
lastPageintegerTotal number of pages
totalintegerTotal matching families
frominteger1-based index of the first item on this page
tointeger1-based index of the last item on this page

Row fields (data[])

FieldTypeDescription
idintegerAttribute family ID
codestringFamily code (e.g. default, apparel)
namestringFamily display name (e.g. Default, Apparel)

The listing is deliberately three columns. Families carry no timestamps at all — there is no createdAt or updatedAt on this resource, unlike every other admin listing — so you cannot sort or filter by date here. Attribute groups and their attributes resolve only on GET /api/admin/catalog/families/{id}.

Sorting

Parameter formExample
Separate sort + order params?sort=id&order=desc

Sortable columns:

sort valueSorts by
idFamily ID (default)
codeFamily code
nameFamily display name

Pagination

  • Default page size: 10 items
  • Maximum page size: 50 items
  • Use ?page=N for page navigation and ?per_page=N to control page size

Errors

HTTP StatusCause
401 UnauthorizedMissing, expired, or revoked admin Bearer token
401 UnauthorizedMissing or invalid admin Bearer token

Unknown filter parameters are silently ignored — no error is returned.

Notes

  • Only 3 columns are returned. The listing mirrors the admin datagrid exactly: id, code, name. No timestamps exist on the attribute_families table. No attribute-group or attribute data is included — use GET /api/admin/catalog/families/{id} for the full nested payload.
  • No automatic filter applied. All families (system and user-defined) are returned by default. There is no is_user_defined filter on families — all families are returned.
  • Envelope-wrapped: { data: [...], meta: { currentPage, perPage, lastPage, total, from, to } }.
  • per_page caps at 50; values ≤ 0 fall back to the default of 10.

Released under the MIT License.