THIS IS NOT AN OFFICIAL API CLIENT, this is just a wrapper for the endpoints from the publisher panel
npm i unity-asset-store-api
import AssetStoreClient from "unity-asset-store-api";
const token = "YOUR_TOKEN_HERE";
const publisherID = 15803;
const client = new AssetStoreClient(token, publisherID, { timeout: 60000 });
// Optionally you can leave the publisher ID undefined
// and pass it as the last argument of each function
await client.apiKey();
await client.downloads(2019, 09);
await client.packages();
await client.publisherOverview();
await client.revenue();
await client.sales(2019, 09);
await client.salesPeriods();
await client.userOverview();
await client.verifyInvoice("INVOICE NO");
await client.logout(); // This invalidates the token
Head over to the asset store publisher panel, open the site cookies and find a cookie named kharma_session
, its value is your token.
Do not make your token publicly available. Logging out invalidates the token.
MIT