Creating Merchant Gateway Package
To create an H-Sphere package file (.hsp), you have to:
- Unpack Merchant Gateway SDK into the merchgateway-sdk directory.
- Modify Deployment Descriptor (merchgateway-sdk/gateway/main.xml)
- Go to the merchgateway-sdk directory and run the "ant stub" command. SDK will generate java class in the merchgateway-sdk/gateway/src directory and merchgateway-sdk/gateway/etc/test-data.in file for testing purposes.
- Modify previously generated java class according to your merchant gateway developer documentation. When your java source is ready, you need to compile this class. Go to the merchgateway-sdk directory and run the "ant compile" command. SDK will compile your java class into the merchgateway-sdk/gateway/build/ directory.
- Create language files for your merchant gateway, and place them into the
- Run the "ant package" command. SDK will create all templates and package files for your gateway in the
If you run "ant" command without any arguments, SDK will compile all classes. If successful, it will execute
junit tests. If all tests are also successful, it will start the packaging process. At the end, you should see the
package_name-version-build.hsp file in the Merchant Gateway SDK base directory. The
build number will be automatically incremented after each build. You can reset it by modifying the
Also, you can run set of test transactions by running the "ant test" command after the merchant gateway java class is compiled.