TypeScript client
import { TxAgentKitClient } from '@tx-agent-kit/sdk'
const client = new TxAgentKitClient({
token: process.env.TX_AGENT_KIT_TOKEN
})
const response = await client.traceLearn.getTraceLearnBillingOverview(){
"plans": [
{
"id": "<string>",
"name": "<string>",
"priceCents": 500000,
"trialDays": 365,
"features": [
"<string>"
],
"description": "<string>",
"maxStudents": 123,
"createdAt": "<string>",
"recommended": true
}
],
"activeSubscription": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
},
"subscriptionSummaries": {
"parentCore": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
},
"tutorStudio": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
}
},
"seatEntitlements": [
{
"id": "<string>",
"subscriptionId": "<string>",
"tutorId": "<string>",
"studentId": "<string>",
"grantedAt": "<string>",
"revokedAt": "<string>"
}
],
"freeDiagnosticAccess": [
{
"id": "<string>",
"parentEmail": "<string>",
"childUsername": "<string>",
"studentId": "<string>",
"diagnosticStartedAt": "<string>",
"diagnosticCompletedAt": "<string>",
"convertedTutorSubscriptionId": "<string>",
"createdAt": "<string>"
}
],
"invoices": [
{
"id": "<string>",
"subscriptionId": "<string>",
"amountCents": 123,
"issuedAt": "<string>",
"dueAt": "<string>",
"paidAt": "<string>",
"periodStart": "<string>",
"periodEnd": "<string>",
"hostedInvoiceUrl": "<string>"
}
],
"paymentMethods": [
{
"id": "<string>",
"subscriptionId": "<string>",
"providerId": "<string>",
"last4": "<string>",
"expiryMonth": 123,
"expiryYear": 123,
"isDefault": true,
"createdAt": "<string>"
}
],
"entitlementSummary": {
"activeSeatCount": 123,
"learnerLimit": 123,
"diagnosticOnlyCount": 123
},
"projectionFreshness": {
"asOf": "<string>",
"stale": true
}
}Smart Cub Learning
Billing overview
GET
/
v1
/
learning
/
billing
/
overview
TypeScript client
import { TxAgentKitClient } from '@tx-agent-kit/sdk'
const client = new TxAgentKitClient({
token: process.env.TX_AGENT_KIT_TOKEN
})
const response = await client.traceLearn.getTraceLearnBillingOverview(){
"plans": [
{
"id": "<string>",
"name": "<string>",
"priceCents": 500000,
"trialDays": 365,
"features": [
"<string>"
],
"description": "<string>",
"maxStudents": 123,
"createdAt": "<string>",
"recommended": true
}
],
"activeSubscription": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
},
"subscriptionSummaries": {
"parentCore": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
},
"tutorStudio": {
"id": "<string>",
"payerId": "<string>",
"planId": "<string>",
"startedAt": "<string>",
"trialEndsAt": "<string>",
"nextBillingDate": "<string>",
"cancelledAt": "<string>",
"seatsPurchased": 123,
"stripeManaged": true,
"studentId": "<string>",
"cancelAtPeriodEnd": true,
"cancelsAt": "<string>"
}
},
"seatEntitlements": [
{
"id": "<string>",
"subscriptionId": "<string>",
"tutorId": "<string>",
"studentId": "<string>",
"grantedAt": "<string>",
"revokedAt": "<string>"
}
],
"freeDiagnosticAccess": [
{
"id": "<string>",
"parentEmail": "<string>",
"childUsername": "<string>",
"studentId": "<string>",
"diagnosticStartedAt": "<string>",
"diagnosticCompletedAt": "<string>",
"convertedTutorSubscriptionId": "<string>",
"createdAt": "<string>"
}
],
"invoices": [
{
"id": "<string>",
"subscriptionId": "<string>",
"amountCents": 123,
"issuedAt": "<string>",
"dueAt": "<string>",
"paidAt": "<string>",
"periodStart": "<string>",
"periodEnd": "<string>",
"hostedInvoiceUrl": "<string>"
}
],
"paymentMethods": [
{
"id": "<string>",
"subscriptionId": "<string>",
"providerId": "<string>",
"last4": "<string>",
"expiryMonth": 123,
"expiryYear": 123,
"isDefault": true,
"createdAt": "<string>"
}
],
"entitlementSummary": {
"activeSeatCount": 123,
"learnerLimit": 123,
"diagnosticOnlyCount": 123
},
"projectionFreshness": {
"asOf": "<string>",
"stale": true
}
}Response
Success
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
⌘I