Skip to content

Environments ​

Environment URLs ​

EnvironmentBase URLDescription
Productionhttps://defi.hashnut.ioThe live environment merchants integrate against

TIP

Work through Prerequisites in order: put a small real order through creation, payment, aggregation, withdrawal and notification callbacks first, and only open up normal-sized traffic once all of that checks out.

Production Networks ​

Chain CodeNetwork Name
ETHEthereum Mainnet
BSCBNB Smart Chain
POLYGONPolygon (Matic)
TRONTron Mainnet

SDK Configuration Examples ​

go
import hashnut "github.com/nuttybounty/hashnut-sdk-go/v4"

// Always pass false as the second argument — that selects the production environment
client := hashnut.NewClient("your-secret-key", false)
// Base URL: https://defi.hashnut.io/api/v4.0.0
go
import hashnut "github.com/nuttybounty/hashnut-sdk-go/v4"

// WithBaseURL overrides the default
client := hashnut.NewClient(
	"your-secret-key",
	false,
	hashnut.WithBaseURL("https://your-custom-endpoint.com/api/v4.0.0"),
)
java
import io.hashnut.client.HashNutClientImpl;
import io.hashnut.service.HashNutServiceImpl;

// Always pass false as the second argument — that selects the production environment
var client = new HashNutClientImpl("your-secret-key", false);
var service = new HashNutServiceImpl(client);
java
import io.hashnut.client.HashNutClientImpl;
import io.hashnut.service.HashNutServiceImpl;

// Passing a string uses it directly as the base URL
var client = new HashNutClientImpl("your-secret-key", "https://your-custom-endpoint.com/api/v4.0.0");
var service = new HashNutServiceImpl(client);

NOTE

The SDKs take only the secretKey. accessKeyId is a per-request parameter (CreateOrderRequest.accessKeyId), not a client constructor argument.

WARNING

A custom base URL must include /api/v4.0.0 — the SDKs append relative paths such as /api/orders/create. Omitting the version segment results in a 404.

REST API Base Paths ​

All API endpoints are prefixed with the version path:

{BASE_URL}/api/v4.0.0/...

For example, the full URL of the create-order endpoint:

https://defi.hashnut.io/api/v4.0.0/api/orders/create

Demo Shop ​

A reference implementation is available at:

ComponentURL
Demo Shop (frontend)https://demo.hashnut.io

The demo shop demonstrates the full payment flow including order creation, payment page, webhook handling, and order status display.