Get Started
To get started using Macrocosmos Software Development Kit (SDK) you should:
Generate your API key using the instruction from the API Keys page
Ensure that you are using Python 3.9+ or Typescript
Install the Macrocosmos SDK using pip or npm
pip install macrocosmos
Macrocosmos SDK should be version 1.0.4+
Client Setup
The Client classes — such as ApexClient
and GravityClient
, serve as the primary interface between your application and a specific Macrocosmos subnet.
# Import the client
import macrocosmos as mc
# Initialize the client
client = mc.ApexClient(api_key="")
When you initialize a client - ApexClient
or GravityClient
, you're creating a scoped connection to that subnet. This setup manages authentication via your API key.
Watch the Demo here
Last updated