Skip to main content

Improved SDK Client Initialization Code Samples

· 2 min read

To improve clarity and onboarding, all client initialization code samples now include relevant code blocks along with import statements. This update makes it easier for developers to understand and use the SDKs, eliminating guesswork around class and function origins in docs and READMEs.

Details​

This change improves consistency and readability across SDKs by showing accurate code blocks based on each language's package structure. Developers can now copy working snippets without searching for package names, streamlining integration. This changelog is a further continuation of the client initialization improvements.

Client Initialization Samples​

Following are the language specific code samples of a typical Payment Client, e.g., configuring a payment client with environment.

Java​

import com.fintech.sdk.Environment;
import com.fintech.sdk.PaymentClient;

public class Program {
public static void main(String[] args) {
PaymentClient client = new PaymentClient.Builder()
.environment(Environment.SANDBOX)
.build();
}
}

C#​

using FintechSdk;

namespace ConsoleApp;

var client = new PaymentClient.Builder()
.Environment(FintechSdk.Environment.Sandbox)
.Build();

Ruby​

require 'fintech-sdk'
include FintechSdk

client = Client.new(
environment: Environment::SANDBOX
)