Account and organization
Get information about your user account, organization, and subscription details.
User information
Retrieve information about the currently authenticated user:
- Shell
- Python
- TypeScript
- C#
curl -X POST https://uthana.com/graphql \
-u $API_KEY: \
-H "Content-Type: application/json" \
-d '{
"query": "{ user { id email email_verified name roles tz tos_accepted survey_completed } }"
}'
import requests
API_URL = 'https://uthana.com/graphql'
API_KEY = '{{apiKey}}'
query = '''
query {
user {
id
email
email_verified
name
roles
tz
tos_accepted
survey_completed
}
}
'''
response = requests.post(
API_URL,
auth=(API_KEY, ''),
json={'query': query}
)
result = response.json()
user = result["data"]["user"]
print(f"User: {user['name']} ({user['email']})")
print(f"Email verified: {user['email_verified']}")
print(f"Roles: {user['roles']}")
const API_URL = "https://uthana.com/graphql";
const API_KEY = "{{apiKey}}";
const authString = btoa(`${API_KEY}:`);
const response = await fetch(API_URL, {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Basic ${authString}`,
},
body: JSON.stringify({
query: `
query {
user {
id
email
email_verified
name
roles
tz
tos_accepted
survey_completed
}
}
`,
}),
});
const json = await response.json();
const user = json.data.user;
console.log(`User: ${user.name} (${user.email})`);
console.log(`Email verified: ${user.email_verified}`);
console.log(`Roles: ${user.roles}`);
private const string ApiUrl = "https://uthana.com/graphql";
private readonly string _apiKey = "{{apiKey}}";
public async Task<User> GetUserAsync()
{
var query = @"
query {
user {
id
email
email_verified
name
roles
tz
tos_accepted
survey_completed
}
}";
var request = new { query = query };
var json = JsonSerializer.Serialize(request);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var authValue = Convert.ToBase64String(Encoding.UTF8.GetBytes($"{_apiKey}:"));
_httpClient.DefaultRequestHeaders.Authorization =
new System.Net.Http.Headers.AuthenticationHeaderValue("Basic", authValue);
var response = await _httpClient.PostAsync(ApiUrl, content);
response.EnsureSuccessStatusCode();
var responseJson = await response.Content.ReadAsStringAsync();
var result = JsonSerializer.Deserialize<GraphQLResponse<UserData>>(responseJson);
return result.Data.User;
}
// Usage
var user = await GetUserAsync();
Console.WriteLine($"User: {user.Name} ({user.Email})");
Console.WriteLine($"Email verified: {user.EmailVerified}");
Console.WriteLine($"Roles: {string.Join(", ", user.Roles)}");
Organization information
Get information about your organization, including download allowances and character limits:
- Shell
- Python
- TypeScript
- C#
curl -X POST https://uthana.com/graphql \
-u $API_KEY: \
-H "Content-Type: application/json" \
-d '{
"query": "{ org { id name motion_download_secs_per_month motion_download_secs_per_month_remaining characters_allowed characters_allowed_remaining users { id name email } } }"
}'
query = '''
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
users {
id
name
email
}
}
}
'''
response = requests.post(
API_URL,
auth=(API_KEY, ''),
json={'query': query}
)
result = response.json()
org = result["data"]["org"]
print(f"Organization: {org['name']}")
print(f"Download allowance: {org['motion_download_secs_per_month']} seconds/month")
print(f"Remaining: {org['motion_download_secs_per_month_remaining']} seconds")
print(f"Characters: {org['characters_allowed_remaining']} of {org['characters_allowed']} remaining")
print(f"Users: {len(org['users'])}")
const response = await fetch(API_URL, {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Basic ${authString}`,
},
body: JSON.stringify({
query: `
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
users {
id
name
email
}
}
}
`,
}),
});
const json = await response.json();
const org = json.data.org;
console.log(`Organization: ${org.name}`);
console.log(`Download allowance: ${org.motion_download_secs_per_month} seconds/month`);
console.log(`Remaining: ${org.motion_download_secs_per_month_remaining} seconds`);
console.log(`Characters: ${org.characters_allowed_remaining} of ${org.characters_allowed} remaining`);
console.log(`Users: ${org.users.length}`);
public async Task<Org> GetOrgAsync()
{
var query = @"
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
users {
id
name
email
}
}
}";
var request = new { query = query };
var json = JsonSerializer.Serialize(request);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await _httpClient.PostAsync(ApiUrl, content);
response.EnsureSuccessStatusCode();
var responseJson = await response.Content.ReadAsStringAsync();
var result = JsonSerializer.Deserialize<GraphQLResponse<OrgData>>(responseJson);
return result.Data.Org;
}
// Usage
var org = await GetOrgAsync();
Console.WriteLine($"Organization: {org.Name}");
Console.WriteLine($"Download allowance: {org.MotionDownloadSecsPerMonth} seconds/month");
Console.WriteLine($"Remaining: {org.MotionDownloadSecsPerMonthRemaining} seconds");
Console.WriteLine($"Characters: {org.CharactersAllowedRemaining} of {org.CharactersAllowed} remaining");
Console.WriteLine($"Users: {org.Users.Count}");
Subscription information
Subscription and billing details are managed through the Uthana web interface. For API access to plan limits and usage, see the Pricing and Rate limits pages.
Tracking usage via API
You can query your organization's usage and limits through the GraphQL API to monitor your balance and set up alerts when approaching limits.
Motion seconds (download allowance)
The org query returns motion download usage directly:
motion_download_secs_per_month— Total seconds of motion downloads allocated to your organization per monthmotion_download_secs_per_month_remaining— Seconds remaining for the current month
motion_download_secs_per_month_remaining updates as you download motions. Use it to check how much of your monthly allowance is left before hitting limits.
Characters (rigs)
The org query returns character usage for the current month:
characters_allowed— Maximum number of characters your organization can create, upload, and/or rig per month (the limit)characters_allowed_remaining— Character creation slots remaining for the current month
characters_allowed_remaining updates as you create (upload, generate, or rig) characters. Use it to check how many character creation slots you have left before hitting limits.
Example query for usage monitoring:
- Shell
- Python
- TypeScript
- C#
curl -X POST https://uthana.com/graphql \
-u $API_KEY: \
-H "Content-Type: application/json" \
-d '{
"query": "{ org { id name motion_download_secs_per_month motion_download_secs_per_month_remaining characters_allowed characters_allowed_remaining } }"
}'
query = '''
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
}
}
'''
response = requests.post(
API_URL,
auth=(API_KEY, ''),
json={'query': query}
)
result = response.json()
org = result["data"]["org"]
print(f"Motion seconds: {org['motion_download_secs_per_month_remaining']} of {org['motion_download_secs_per_month']} remaining")
print(f"Characters: {org['characters_allowed_remaining']} of {org['characters_allowed']} remaining")
const response = await fetch(API_URL, {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Basic ${authString}`,
},
body: JSON.stringify({
query: `
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
}
}
`,
}),
});
const json = await response.json();
const org = json.data.org;
console.log(
`Motion seconds: ${org.motion_download_secs_per_month_remaining} of ${org.motion_download_secs_per_month} remaining`,
);
console.log(`Characters: ${org.characters_allowed_remaining} of ${org.characters_allowed} remaining`);
var query = @"
query {
org {
id
name
motion_download_secs_per_month
motion_download_secs_per_month_remaining
characters_allowed
characters_allowed_remaining
}
}";
var request = new { query = query };
var json = JsonSerializer.Serialize(request);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await _httpClient.PostAsync(ApiUrl, content);
response.EnsureSuccessStatusCode();
var responseJson = await response.Content.ReadAsStringAsync();
var result = JsonSerializer.Deserialize<GraphQLResponse<OrgData>>(responseJson);
var org = result.Data.Org;
Console.WriteLine($"Motion seconds: {org.MotionDownloadSecsPerMonthRemaining} of {org.MotionDownloadSecsPerMonth} remaining");
Console.WriteLine($"Characters: {org.CharactersAllowedRemaining} of {org.CharactersAllowed} remaining");
Next steps
- Explore Asset management for managing your characters and motions
- Check the API reference for complete schema documentation