0.2.21 • Published 11 months ago

medusa-plugin-algolia v0.2.21

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

Algolia

Provide powerful indexing and searching features in your commerce application with Algolia.

Algolia Plugin Documentation | Medusa Website | Medusa Repository

Features

  • Flexible configurations for specifying searchable and retrievable attributes.
  • Ready-integration with Medusa's Next.js starter storefront.
  • Utilize Algolia's powerful search functionalities including typo-tolerance, query suggestions, results ranking, and more.

Prerequisites


How to Install

1. Run the following command in the directory of the Medusa backend:

npm install medusa-plugin-algolia

2. Set the following environment variables in .env:

ALGOLIA_APP_ID=<YOUR_APP_ID>
ALGOLIA_ADMIN_API_KEY=<YOUR_ADMIN_API_KEY>

3. In medusa-config.js add the following at the end of the plugins array:

const plugins = [
// ...
{
  resolve: `medusa-plugin-algolia`,
  options: {
    applicationId: process.env.ALGOLIA_APP_ID,
    adminApiKey: process.env.ALGOLIA_ADMIN_API_KEY,
    settings: {
      products: {
        indexSettings: {
          searchableAttributes: ["title", "description"],
          attributesToRetrieve: [
            "id",
            "title",
            "description",
            "handle",
            "thumbnail",
            "variants",
            "variant_sku",
            "options",
            "collection_title",
            "collection_handle",
            "images",
          ],
        },
        transformer: (product) => ({ 
          id: product.id, 
          // other attributes...
        }),
      },
    },
  },
},
]

Test the Plugin

1. Run the following command in the directory of the Medusa backend to run the backend:

npm run start

2. Try searching products either using your storefront or using the Store APIs.


Additional Resources

0.2.21

11 months ago

0.2.20

2 years ago

0.2.19

2 years ago

0.2.18

2 years ago

0.2.17

2 years ago

0.2.16

2 years ago

0.2.15

2 years ago

0.2.14

2 years ago

0.2.13

2 years ago

0.2.12

2 years ago

0.2.11

2 years ago

0.2.10

2 years ago

0.2.10-rc.3

2 years ago

0.2.10-rc.2

2 years ago

0.2.10-rc.1

2 years ago

0.2.10-rc.0

2 years ago

0.2.7

2 years ago

0.2.9

2 years ago

0.2.8

2 years ago

0.2.6

3 years ago

0.2.5-test.0

3 years ago

0.2.5-next.0

3 years ago

0.2.6-alpha.0

3 years ago

0.2.5-nxt.0

3 years ago

0.2.6-alp.0

3 years ago

0.2.5

3 years ago

0.2.1-next.99

3 years ago

0.2.1-next.35

3 years ago

0.2.1-nxt.129

3 years ago

0.2.1-next.41

3 years ago

0.2.1-next.101

3 years ago

1.0.0-next.0

3 years ago

0.2.1-next.100

3 years ago

0.2.1-next.44

3 years ago

0.2.1-next.24

3 years ago

0.2.1-next.26

3 years ago

0.2.1-next.27

3 years ago

0.2.1

3 years ago

0.2.1-nxt.130

3 years ago

0.2.3

3 years ago

0.2.1-next.108

3 years ago

0.2.2

3 years ago

0.2.4

3 years ago

0.2.1-next.14

3 years ago

0.0.10-next.0

3 years ago

0.2.0

3 years ago

0.0.9

3 years ago

0.0.9-alpha.63

3 years ago

0.1.2-dev.53

3 years ago

0.1.2-dev.56

3 years ago

0.1.2-dev.47

3 years ago

0.1.0

3 years ago

0.1.1

3 years ago

0.0.7-adminc.74

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.7-alpha.52

3 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.2-alpha.1474

4 years ago