> For the complete documentation index, see [llms.txt](https://docs.mindplug.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mindplug.io/api/query-by-ids.md).

# Query By Ids

### Prerequisites

Requires a user auth token. See the [API Auth](/api/api-setup-text.md) section.

### Getting vectors

Fetches data on specific vectors given vector ids.

```typescript
import mindplug from "@/src/mindplugAPI"; // base instance

mindplug.post("/data/vectors", {
    "db": "walmart",
    "collection": "OfficeSupplies",
    "vectorIds": ["22dd234c-340f-4c85-b784-47645bcdf07a",  "c8c47178-cba5-4795-a6ef-67fd4eda70fa"]
});
```

Returns the vector data related to the given vectors

```json
{
    "data": [
        {
            "id": "0b1a591b-bf13-4c3a-a667-81c9da5bf75f",
            "metadata": {
                "content": "Premium eraser: an erases that works on both pen and pencil and leaves no crumbs",
                "description": "Premium eraser: an erases that works on both pen and pencil and leaves no crumbs",
                "id": 1234335
            }
        }
    ]
}
```
