Skip to main content
GET
/
api
/
v1
/
operations
/
credits
/
balance
curl -X GET "https://app.lance.so/api/v1/operations/credits/balance" \
  -H "Authorization: Bearer <token>"
{
  "balance": 1500,
  "organizationId": "org_2abc123def456"
}
This endpoint returns the current credit balance for the organization associated with the authenticated user. Credits are used for various enrichment operations within the platform.

Authentication

This endpoint requires authentication. The organization ID is automatically determined from the authenticated session.

Request

This endpoint does not require any request parameters. The organization is identified automatically from the authentication context.

Response

balance
integer
required
The current credit balance for the organization. This is a non-negative integer representing the total available credits. Example: 1500
organizationId
string
required
The unique identifier of the organization whose balance was retrieved. Example: org_2abc123def456

Credit Usage

Credits are consumed when performing enrichment operations:
Operation TypeDescription
enrichment_emailEmail address enrichment
enrichment_phonePhone number enrichment
enrichment_combinedCombined email and phone enrichment
linkedin_enrichmentLinkedIn profile enrichment

Credit Sources

Credits can be added to an organization through several sources:
SourceDescription
stripe_subscriptionMonthly subscription allocation
stripe_purchaseOne-time credit purchase
signup_bonusWelcome bonus for new organizations
manualManual credit adjustment by admin
curl -X GET "https://app.lance.so/api/v1/operations/credits/balance" \
  -H "Authorization: Bearer <token>"
{
  "balance": 1500,
  "organizationId": "org_2abc123def456"
}

Error Codes

Status CodeError CodeDescription
400VALIDATION_ERRORUser is not authenticated or not associated with an organization
500INTERNAL_ERRORServer error while retrieving balance

Notes

  • The balance is calculated as the sum of all credit transactions (additions minus consumptions) for the organization
  • Balance can be zero but never negative - the system prevents operations that would result in negative balance
  • New organizations receive a signup bonus upon first access