Skip to main content

Introspection — GET /v1/me

Returns everything an SDK or MCP client needs to know about itself: which organization it belongs to, what scopes its API key has, what plan the org is on, and where it stands against the plan's limits.

Call this first when initializing your integration. It eliminates the need to hardcode organization_id in config and lets your app surface "you've used 38 / 50 AI credits this month" without listing every generation.

Request

curl https://app.posteverywhere.ai/api/v1/me \
-H "Authorization: Bearer $POSTEVERYWHERE_API_KEY"

Requires read scope. Counts against the API rate limit.

Response

{
"api_key": {
"id": "fb382fa0-...",
"key_prefix": "pe_live_4f3c",
"name": "Production server",
"scopes": ["read", "write", "ai"],
"last_used_at": "2026-06-11T05:30:00Z",
"created_at": "2026-04-01T...",
"expires_at": null
},
"scopes": ["read", "write", "ai"],

"user": {
"id": 8476,
"email": "[email protected]",
"name": "Netanel"
},

"organization": {
"id": "56cb4496-...",
"name": "Sweeppy Inc.",
"subscription_plan": "GROWTH",
"subscription_status": "active",
"subscription_source": "stripe",
"trial_end": null,
"current_period_end": "2026-07-11T...",
"cancel_at_period_end": false,
"entitled": true
},

"workspace": {
"id": "ea0589e2-...",
"name": "Marketing"
},

"quota": {
"accounts": { "used": 6, "limit": 25 },
"ai_credits": { "used": 138, "limit": 500, "bonus": 0 },
"storage_bytes": { "used": 4283392104, "limit": 26843545600 },
"team_seats": { "limit": 3 }
},

"stats": {
"posts_last_30d": 214,
"total_posts": 832
}
}

Notable fields

  • organization.entitled — derived boolean. true when subscription_status is active or trialing. Use this as the single source of truth for "should I let this user post?"
  • organization.subscription_sourcestripe, revenuecat (iOS IAP), or admin_comp (comped account). admin_comp accounts don't have Stripe billing; their entitlement is granted directly.
  • quota.ai_credits.bonus — credits purchased via the credit-pack flow, added on top of the monthly allotment.
  • api_key.expires_atnull for keys that don't expire.

Common patterns

Check before generating

const me = await client.getMe();
if (me.quota.ai_credits.limit - me.quota.ai_credits.used < 5) {
showUpgradePrompt();
return;
}
await client.generateImage({ prompt: "..." });

Surface entitlement state

const me = await client.getMe();
if (!me.organization.entitled) {
// Subscription expired / canceled / past_due
redirect("/billing");
}

Auto-discover organization_id

// In your SDK init — no need to ask the user for org_id.
const me = await client.getMe();
this.organizationId = me.organization.id;