medusa-payment-hydrogen
v1.0.1
Published
Hydrogen Payment provider for Medusa Commerce
Downloads
122
Maintainers
Readme
Medusa Hydrogen Payment Plugin
About
medusa-payment-hydrogen
is a Medusa plugin that adds Hydrogen as a payment provider to Medusa ecommerce stores.
Prerequisites
- Hydrogen account
- Hydrogen account's secret key
- Medusa server
Medusa Server
If you don’t have a Medusa server installed yet, you must follow the quickstart guide first.
Install the Hydrogen Plugin
In the root of your Medusa server, run the following command to install the Hydrogen plugin:
yarn add medusa-payment-hydrogen
Configure the Hydrogen Plugin
Next, you need to enable the plugin in your Medusa server.
In medusa-config.js
add the following to the plugins
array:
const plugins = [
// other plugins
{
resolve: `medusa-payment-hydrogen`,
/** @type {import("medusa-payment-hydrogen").PluginOptions} */
options: {
secret_key: "<HYDROGEN_SECRET_KEY>",
callback_url: "<YOUR_MEDUSA_BACKEND_URL>/hydrogen/hooks",
},
},
];