Environments & Authentication
We offer two environments to make it easy for you to develop - a sandbox environment for testing purposes, and a production environment once you're ready. The two environments always have the same feature set, but the main difference is that one is deployed on the Polygon Mumbai Testnet, while the other is deployed on the Polygon mainnet. Only use the production environment when you've finished building the integration!
- Network: Mumbai
- API Endpoint:
https://sandbox-api.mintkudos.xyz/v1
- Chain ID: 80001 (necessary when signing the token creation message)
- Verifying Contract:
0xB876baF8F69cD35fb96A17a599b070FBdD18A6a1
- Network: Polygon
- API Endpoint:
https://api.mintkudos.xyz/v1
- Chain ID: 137 (necessary when signing the token creation message)
- Verifying Contract:
0x60576A64851C5B42e8c57E3E4A5cF3CF4eEb2ED6
You may have noticed that some API calls, such as the
/communities/:communityId
endpoints and the POST /tokens
endpoint, require an API key. As we are still a developing product & team, we want to make sure that we can iterate with our valued partners & users. To ensure that we can provide the best experience & support possible, we are not providing the API key openly. Please follow the instructions below to obtain an API key:- 1.
- 2.Once you onboard as a community, contact us via the #developers channel in our Discord server. Let us know that you want to use the MintKudos API with the following information:
- your
communityId
- your ETH address
- what you're trying to use the MintKudos API for
The API key is used to make calls that are auth-gated. We leverage Basic Auth. Follow these steps to make sure that your API calls are properly authenticated:
- 1.Obtain the
communityId
andAPI Key
from us (note that you will use the samecommunityId
in the/communites/:communityId
endpoints) - 2.Combine the
communityId
andAPI Key
with a colon and then base64 encode the string - 3.Attach the encoded string to the
Authorization
field of the API request’s header. Don’t forget the wordBasic
in front of the encoded string! - 4.Make the call 🪄
Example code (TS)
const encodedString = btoa(communityId + ":" + apiKey)
const config = {
headers: {
"Authorization": `Basic ${encodedString}`
},
};
const result = await axios.get(
`https://api.mintkudos.xyz/v1/communities/${communityId}/configuration`,
config,
);
console.log(result.data); // ex: { remainingCustomImageCount: 0 }
Last modified 4mo ago