# JSON.ARRINDEX

> Search for the first occurrence of a JSON value in an array.

## Arguments

<ParamField body="key" type="str" required>
    The key of the json entry.
</ParamField>
<ParamField body="path" type="str" required>
    The path of the array.
</ParamField>

<ParamField body="value" type="TValue" required>
    The value to search for.
</ParamField>

<ParamField body="start" type="int" default={0}>
    The start index.
</ParamField>
<ParamField body="stop" type="int" default={0}>
    The stop index.
</ParamField>


## Response

<ResponseField type="List[int]" required>
  The index of the first occurrence of the value in the array, or -1 if not found.
</ResponseField>

<RequestExample>
```py Example
index = redis.json.arrindex("key", "$.path.to.array", "a")
```
</RequestExample>
