Skip to content

Latest commit

 

History

History
45 lines (32 loc) · 1.04 KB

ListMeta.md

File metadata and controls

45 lines (32 loc) · 1.04 KB

ListMeta

Pagination block of the {data, meta} list envelope. Lists take page + per_page (capped per endpoint) or offset + limit; per_page=all returns the whole set in one page.

Properties

Name Type
total number
perPage number
currentPage number
lastPage number
limit number
offset number

Example

import type { ListMeta } from 'goadserver-sdk'

// TODO: Update the object below with actual values
const example = {
  "total": null,
  "perPage": null,
  "currentPage": null,
  "lastPage": null,
  "limit": null,
  "offset": null,
} satisfies ListMeta

console.log(example)

// Convert the instance to a JSON string
const exampleJSON: string = JSON.stringify(example)
console.log(exampleJSON)

// Parse the JSON string back to an object
const exampleParsed = JSON.parse(exampleJSON) as ListMeta
console.log(exampleParsed)

[Back to top] [Back to API list] [Back to Model list] [Back to README]