Account Credits API

Narakeet provides an API endpoint for retrieving your available account credits. This is mostly useful for developers who integrate Narakeet into their own applications but pre-pay credits using a top-up plan, so they can check available credits and top-up before they run out of capacity.

This page explains how to use the account credits endpoint.

API Endpoint

The API endpoint that lists voices is available at https://api.narakeet.com/account/credits

Authenticating requests

To use the API, you will need a Narakeet API key. For information on how to get a key, check out our guide on Managing API Keys.

You should provide the API key as a header to all requests to the public REST endpoints, using the x-api-key header.

How to use the API to list available credits

To request a list of available voices:

  • Use the GET HTTP method
  • Invoke the endpoint at https://api.narakeet.com/account/credits
  • Provide your API key in the x-api-key header
  • Parse the response as JSON, and read the creditSeconds property

The creditSeconds result property contains the available credits for your account, measured in seconds.

CURL example

To execute the API call from a command line using CURL, use the following command (and set the $NARAKEET_API_KEY environment variable, or replace that in the call with your API key):

curl -X GET -H "x-api-key: $NARAKEET_API_KEY" https://api.narakeet.com/account/credits

Result structure

The response is a JSON object, containing elements with the following properties

  • creditSeconds: integer, the quantity of credit seconds still available for your account to create audio/video materials
  • requestId: string, internal request ID of your API call
  • identity: string, the ID of this API access key - you will need this if you want to contact us about any billing queries
  • billingId: string the id of this billing plan - you will need this if you want to contact us about any billing queries
  • plan: string, the billing plan type this account is associated with (for top-up accounts, it will be “TOPUP”).

Pricing

There is no cost to use this endpoint, since you are not building any content with it. However, using the endpoint counts towards your maximum call limit per day.

More information

  • For general API limitations and pricing, see the main Developer API page.