await client.ft.create('idx1', { '$.id': { type: SchemaFieldTypes.NUMERIC, AS: 'id' }, '$.gender': { type: SchemaFieldTypes.TAG, AS: 'gender' }, '$.season.*': { type: SchemaFieldTypes.TAG, AS: 'season' }, '$.description': { type: SchemaFieldTypes.TEXT, AS: 'description' }, '$.price': { type: SchemaFieldTypes.NUMERIC, AS: 'price' }, '$.city': { type: SchemaFieldTypes.TEXT, AS: 'city' }, '$.coords': { type: SchemaFieldTypes.GEO, AS: 'coords' } }, { ON: 'JSON', PREFIX: 'product:'}); await client.json.set('product:15970', '$', {"id": 15970, "gender": "Men", "season":["Fall", "Winter"], "description": "Turtle Check Men Navy Blue Shirt", "price": 34.95, "city": "Boston", "coords": "-71.057083, 42.361145"}); await client.json.set('product:59263', '$', {"id": 59263, "gender": "Women", "season":["Fall", "Winter", "Spring", "Summer"],"description": "Titan Women Silver Watch", "price": 129.99, "city": "Dallas", "coords": "-96.808891, 32.779167"}); await client.json.set('product:46885', '$', {"id": 46885, "gender": "Boys", "season":["Fall"], "description": "Ben 10 Boys Navy Blue Slippers", "price": 45.99, "city": "Denver", "coords": "-104.991531, 39.742043"}); result = await client.ft.search('idx1', '@price:[40,130]'); console.log(JSON.stringify(result, null, 4));