Skip to content

Overview

This section serves as the reference for the Trinsic API, which can be accessed using any of our SDKs.

Authentication

Authentication with the Trinsic platform uses auth tokens, which are strings that operate similarly to API keys. You can get an auth token from the Dashboard.

Using Auth Tokens in the SDK

Tokens are passed to the SDK during service instantiation as part of the TrinsicOptions.

Services

Our SDK is broken down into the following logical APIs, each of which is accessible through a single TrinsicService instance:

Using an SDK Service

If you are using one of the Trinsic SDKs, you will need to create an instance of a TrinsicService in order to use it.

using Trinsic;

var trinsic = new TrinsicService();
// or instantiate with auth token
// var trinsic = new TrinsicService(new TrinsicOptions { AuthToken = "<auth token>" });
trinsic_service = TrinsicService(server_config=trinsic_config())
trinsic, err := NewTrinsic(WithTestEnv())
assert2.Nil(err)
var serverConfig = TrinsicUtilities.getTrinsicTrinsicOptions();
var trinsic = new TrinsicService(serverConfig);

The constructor accepts a ServiceOptions object as an argument, allowing you to specify a default ecosystem and other configuration properties:

Cannot print proto message: Cannot find protobuf object with name sdk.options.v1.ServiceOptions

The exact structure of this object will depend on the language you are working with. You can always rely on your editor's intellisense when in doubt.