# Pagination

By default a `restapi/1.0/object/{object_name}` will return the ids of all records matching the condition, which may be a huge number. `offset` and `limit` parameters are available to only retrieve a subset of all matched records.

**Request:**

```
GET /restapi/1.0/object/res.partner/search?domain=[('is_company','=',True),('customer','=',True)]&offset=10&limit=5 HTTP/1.1
Host: {your_Odoo_server_url}
```

**JSON Response:**

```
HTTP/1.1 200 OK

{
  'Partner': [
      13, 20, 30, 22, 29
  ]
}
```

**XML Response:**

```
HTTP/1.1 200 OK

<res.partner type="list">
    <item type="int">13</item>
    <item type="int">20</item>
    <item type="int">30</item>
    <item type="int">22</item>
    <item type="int">29</item>
</res.partner>
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://synconics.gitbook.io/rest-api/calling-methods/list-records/pagination.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
