Skip to main content
GET
/
me
curl https://api.poof.bg/v1/me \
  -H "x-api-key: YOUR_API_KEY"
{
  "organizationId": "org_abc123xyz",
  "plan": "Pro",
  "maxCredits": 5000,
  "usedCredits": 1234,
  "autoRechargeThreshold": 100
}
Get information about your account including your current plan, credit balance, and usage statistics.

Request

No request body required. Just include your API key in the header.
curl https://api.poof.bg/v1/me \
  -H "x-api-key: YOUR_API_KEY"

Response

organizationId
string
Your unique organization identifier.
plan
string
Your current subscription plan (e.g., “Free”, “Pro”, “Enterprise”).
maxCredits
integer
Total credits available in your current billing cycle.
usedCredits
integer
Credits consumed in the current billing cycle.
autoRechargeThreshold
integer | null
If auto-recharge is enabled, the credit threshold that triggers a top-up. null if disabled.
{
  "organizationId": "org_abc123xyz",
  "plan": "Pro",
  "maxCredits": 5000,
  "usedCredits": 1234,
  "autoRechargeThreshold": 100
}

Examples

curl https://api.poof.bg/v1/me \
  -H "x-api-key: YOUR_API_KEY"

Use Cases

Monitoring Usage

Check your credit consumption before processing a batch:
account = client.get_account()
remaining = account.max_credits - account.used_credits

if remaining < 100:
    print("Warning: Low credits, consider upgrading")

Usage Dashboard

Display account info in your application:
const account = await poof.getAccount();

const usagePercent = (account.usedCredits / account.maxCredits) * 100;
console.log(`Usage: ${usagePercent.toFixed(1)}%`);

Pre-flight Check

Verify credentials and check limits before starting a job:
try:
    account = client.get_account()
    images_to_process = 500
    remaining = account.max_credits - account.used_credits
    
    if remaining < images_to_process:
        raise Exception(f"Not enough credits. Need {images_to_process}, have {remaining}")
    
    # Proceed with processing
except AuthenticationError:
    print("Invalid API key")

Error Responses

StatusCodeDescription
401authentication_errorInvalid or missing API key
curl https://api.poof.bg/v1/me \
  -H "x-api-key: YOUR_API_KEY"