Getting Started with Payment Extension
This page provides all the steps needed to create your first payment extension. It covers the following tasks:
- Install Fynd Development Kit Command-line Interface (FDK-CLI)
- Generate the Boilerplate
- Download the Boilerplate
- Preview your Extension
Prerequisites
Before getting started, you will need the following:
- Git↗
- Node.js v20↗ or later
- Account in Fynd Partners↗
- Development Company. Refer to Development Company to create a development company.
1. Install the FDK CLI
The FDK CLI simplifies extension development by providing commands for creating, testing, and deploying extension. For more details, refer to the GitHub documentation↗.
- Run the following command in your terminal to install FDK CLI:
npm install -g @gofynd/fdk-cli
- Run
fdk --versionto ensure that the FDK CLI version is 8.0.4 or later to create a payment extension in the FDK CLI.
2. Generate a Boilerplate
After you successfully installed the FDK CLI, do the following steps to generate a payment boilerplate:
- Run the following command to log into your Fynd Partner account:
fdk login
- Select the organization for which you want to create the extension.
After login, you can run fdk user to verify if you've logged in.
- Go back to your terminal and run the following command to initiate a new extension:
fdk extension init
The fdk extension init command creates a folder in your local system and downloads the boilerplate for you to get started. This command also registers the extension in the Fynd Partner's account. You can change all the extension details in the Fynd Partners panel.
- Select Create new extension.
- Enter a name for your extension. Here, we have entered Power Partner.
- Select the extension type as Private.
- Select the extension launch type as Payment.
- Enter a unique payment slug. Here, we have entered power-partner-1.
- Select
Node + React.js + SQLiteas your preferred technology stack for the template. This will create a boilerplate directory in your local system, and a payment extension will be registered in Fynd Partners. The extension URL will appear in your terminal.