# Get an Item's History

Use this method to get an Item's Transaction History.&#x20;

### Usage in your script

{% tabs %}
{% tab title="JavaScript" %}

```javascript
const response = await alturaItem.getHistory();

// customize options
const response = await alturaItem.getHistory({
  perPage: 20,
  page: 1
});

const history = response.events;
```

{% endtab %}

{% tab title="TypeScript" %}

```typescript
const response: {events: IAlturaEvent[]} = await alturaItem.getHistory();

// customize options
const response: {events: IAlturaEvent[]} = await alturaItem.getHistory({
  perPage: 20,
  page: 1
});

const history = response.events;
```

{% endtab %}
{% endtabs %}

### **Parameters**

<table><thead><tr><th width="193">Parameter</th><th width="99">Type</th><th width="105">Required</th><th>Description</th></tr></thead><tbody><tr><td>perPage</td><td>number</td><td><strong>Optional</strong></td><td>The number of events to return</td></tr><tr><td>page</td><td>number</td><td></td><td>The offset for returned items. Calculated as (page - 1) * perPage</td></tr></tbody></table>

### Event Object

```javascript
export interface IAlturaEvevnt {
  id: string;
  amount: string;
  blockNumber: number;
  chainId: number;
  event: string;
  from: string;
  itemCollection: string;
  itemRef: string;
  timestamp: number;
  to: string;
  tokenId: number;
  transactionHash: string;
}
```


---

# 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://docs.altura.com/altura-documentation/js-sdk-reference/get-methods/get-an-items-history.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.
