> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hacktron.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get credit balance

> Read the organization's pentest credit balance.

Returns the pentest credits available to the organization, with totals purchased, used, refunded and granted. `is_unlimited` is true for organizations without a credit limit.

> [!NOTE]
>
> **Scope required**: `read`


## OpenAPI

````yaml GET /credits
openapi: 3.0.0
info:
  title: Hacktron REST API
  description: Public REST API for programmatic access to Hacktron
  version: '1.0'
  contact: {}
servers:
  - url: https://api.hacktron.ai/v1
security:
  - api-key: []
tags: []
paths:
  /credits:
    get:
      tags:
        - REST API - Credits
      summary: The organization's pentest credit balance
      operationId: RestCreditController_balance
      parameters: []
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PentestCreditBalanceResponseDto'
components:
  schemas:
    PentestCreditBalanceResponseDto:
      type: object
      properties:
        organization_id:
          type: string
          description: Organization UUID
          example: f336d0bc-b841-465b-8045-024475c079dd
        balance:
          type: number
          description: Current pentest credit balance available for use
          example: 12000
        total_purchased:
          type: number
          description: Total pentest credits purchased across all time
          example: 16000
        total_used:
          type: number
          description: Total pentest credits deducted for completed/running pentests
          example: 8000
        total_refunded:
          type: number
          description: Total pentest credits refunded from cancelled pentests
          example: 4000
        total_granted:
          type: number
          description: Total pentest credits granted at no charge
          example: 2000
        used_this_period:
          type: number
          nullable: true
          description: >-
            Credits deducted since the start of the current billing period, null
            when the organization has no billing period
          example: 1240
        is_unlimited:
          type: boolean
          description: Whether this organization has internal unlimited pentest entitlement
          example: false
      required:
        - organization_id
        - balance
        - total_purchased
        - total_used
        - total_refunded
        - total_granted
        - used_this_period
        - is_unlimited
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: X-Api-Key

````

## Related topics

- [Get Started](https://docs.hacktron.ai/mcp/get-started.md)
- [Automation credits](https://docs.hacktron.ai/platform/automations/credits.md)
- [Credits and billing](https://docs.hacktron.ai/white-box-pentest/billing.md)
- [Quickstart](https://docs.hacktron.ai/white-box-pentest/quickstart.md)
- [Billing](https://docs.hacktron.ai/platform/billing.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.