SettleMint
Developer guidesAPI integration

API reference

Access the OpenAPI specification and generate type-safe clients for integrating with the DALP platform programmatically.

The DALP platform exposes a complete REST API with an auto-generated OpenAPI 3.x specification. You can explore endpoints interactively, generate client SDKs for your language, or integrate with API testing tools.

REST API documentation with full endpoint reference

OpenAPI specification endpoint

The OpenAPI spec is served at your platform's /api/ path:

Open API Explorer

This endpoint returns a JSON document conforming to the OpenAPI 3.x specification. The spec includes:

  • Endpoint definitions – All available routes organized by namespace (token, system, user, etc.)
  • Request schemas – Parameter types, validation rules, and required fields
  • Response schemas – Return types for successful responses and error codes
  • Authentication – Security scheme using X-Api-Key header
  • Examples – Sample requests and responses for common operations

Viewing the specification

In your browser:

Visit /api on your platform (e.g., https://your-platform.example.com/api) to see the interactive API documentation powered by OpenAPI Reference Plugin.

With curl:

curl https://your-platform.example.com/openapi.json | jq

In Postman/Insomnia:

Import the OpenAPI spec URL to auto-generate a collection with all endpoints configured.


Authentication

All API requests require authentication, either via an API key in the X-Api-Key header or a session cookie. When using session-based (cookie) authentication, sensitive operations that trigger blockchain transactions also require wallet verification. When using API key authentication, wallet verification is skipped automatically — the walletVerification field can be omitted.

See Getting started for API key creation and client configuration.


Response headers

Transaction hash header

Mutation operations that submit blockchain transactions return the transaction hash in the X-Transaction-Hash response header.

The API automatically waits for transaction confirmation—you typically don't need this header. However, if you receive a CONFIRMATION_TIMEOUT error, use the hash to check whether the transaction eventually succeeded before retrying.

See Transaction tracking for timeout recovery patterns.


API namespaces

The API is organized into logical namespaces, each containing related procedures:

NamespaceDescriptionExample operations
tokenToken CRUD, supply management, compliance, statstoken.create, token.mint, token.burn, token.transfer, token.freezeAddress
transactionBlockchain transaction status trackingtransaction.read
systemPlatform infrastructure (access control, identity, claims)system.accessManager.grantRole, system.identity.register, system.trustedIssuers.create
userUser profile and organization membershipuser.me, user.update
accountBlockchain wallet and identity managementaccount.identity, account.claims
actionsScheduled tasks and executable operationsactions.list, actions.read
addonsOptional features (token sale, fixed yield)addons.tokenSale.create, addons.fixedYield.configure
contactsAddress book for frequent recipientscontacts.list, contacts.create
exchangeRatesForeign exchange rates for multi-currency assetsexchangeRates.list, exchangeRates.convert
searchGlobal search across tokens, contacts, transactionssearch.query
settingsPlatform configuration and preferencessettings.get, settings.update
externalTokenImport and track tokens from other systemsexternalToken.register, externalToken.list
authBetter Auth endpoints (sign-in, sessions, passkeys)/auth/sign-in, /auth/session, /auth/passkey/create

Each namespace is prefixed in the API path. For example, token.create maps to POST /api/token/create.

User statistics data sources

User statistics endpoints (user.stats, user.statsUserCount, user.statsGrowthOverTime) report counts based on organization membership data in the DALP database. Recent activity is derived from each member's most recent login timestamp, falling back to their created date when login history is unavailable.


TypeScript SDK

Generate a type-safe client from the OpenAPI specification using @hey-api/openapi-ts. The generated SDK provides full IntelliSense, request/response types, and BigDecimal helpers.

See Getting started for SDK generation and client configuration.


Using with API tools

Swagger UI

Swagger UI provides an interactive API explorer:

  1. Open /api in your browser (e.g., https://your-platform.example.com/api)
  2. The OpenAPI Reference Plugin serves a styled documentation page
  3. Expand endpoint groups to see request schemas and examples
  4. Click "Try it out" to execute requests directly from the browser

Redoc

For a cleaner, read-only documentation view:

  1. Download the OpenAPI spec: curl https://your-platform.example.com/openapi.json > openapi.json
  2. Serve with Redoc:
    npx @redocly/cli preview-docs openapi.json
  3. Open http://localhost:8080 in your browser

Postman

Import the OpenAPI spec into Postman:

  1. Click Import in Postman
  2. Select Link tab
  3. Paste: https://your-platform.example.com/openapi.json
  4. Click ContinueImport
  5. Configure the collection's authorization with your API key:
    • Auth Type: API Key
    • Key: X-Api-Key
    • Value: sm_dalp_xxxxxxxxxxxxxxxx
    • Add to: Header

Insomnia

Import the OpenAPI spec into Insomnia:

  1. Click CreateImport
  2. Paste: https://your-platform.example.com/openapi.json
  3. Click ScanImport
  4. Add an environment variable for X-Api-Key header

curl examples

Fetch user profile:

curl -X POST https://your-platform.example.com/api/user/me \
  -H "X-Api-Key: sm_dalp_xxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{}'

List tokens:

curl -X POST https://your-platform.example.com/api/token \
  -H "X-Api-Key: sm_dalp_xxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{"limit": 10, "offset": 0}'

Create a token (API key auth — no walletVerification needed):

curl -X POST https://your-platform.example.com/api/token/create \
  -H "X-Api-Key: sm_dalp_xxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "stablecoin",
    "name": "Test USD Coin",
    "symbol": "TUSD",
    "decimals": 6,
    "countryCode": "840",
    "priceCurrency": "USD",
    "basePrice": ["100", 2],
    "initialModulePairs": []
  }'

When using session-based authentication, add the walletVerification field:

curl -X POST https://your-platform.example.com/api/token/create \
  -H "Cookie: session=..." \
  -H "Content-Type: application/json" \
  -d '{
    "type": "stablecoin",
    "name": "Test USD Coin",
    "symbol": "TUSD",
    "decimals": 6,
    "countryCode": "840",
    "priceCurrency": "USD",
    "basePrice": ["100", 2],
    "initialModulePairs": [],
    "walletVerification": {
      "verificationType": "PINCODE",
      "secretVerificationCode": "123456"
    }
  }'

Generating client SDKs

Use the OpenAPI spec to generate clients for languages beyond TypeScript.

Python (openapi-generator)

openapi-generator-cli generate \
  -i https://your-platform.example.com/openapi.json \
  -g python \
  -o ./dalp-python-client

Go

openapi-generator-cli generate \
  -i https://your-platform.example.com/openapi.json \
  -g go \
  -o ./dalp-go-client

C# / .NET

openapi-generator-cli generate \
  -i https://your-platform.example.com/openapi.json \
  -g csharp-netcore \
  -o ./dalp-csharp-client

Java

openapi-generator-cli generate \
  -i https://your-platform.example.com/openapi.json \
  -g java \
  -o ./dalp-java-client

Note: Generated clients may require manual adjustments for BigInt/BigDecimal serialization. The TypeScript SDK includes toBigDecimal() and fromBigDecimal() helpers for this purpose.


Error handling

The API returns standardized HTTP status codes and machine-readable error codes. Errors include detailed messages and contextual data to help diagnose issues.

See Error handling for the complete error reference, retry strategies, and blockchain revert reasons.


Next steps

On this page