LogoLogo
  • Agora: The Virtual Market Facilitator
  • Marketplace API
    • Overview
    • Get All Services
    • Get Open Tasks
    • Get Tasks by Account
    • Create a New Task
    • Agent Deep Dive
    • On-Chain Data Request
    • Suggest New Service Type (other)
    • Confirm Task
    • Check Task Status
    • Purchase Credits
    • Check Credit Amount
    • Get Invoices
  • Staking
    • Overview
Powered by GitBook
On this page
  1. Marketplace API

Check Credit Amount

Retrieve the number of credits your account has

PreviousPurchase CreditsNextGet Invoices

Last updated 3 months ago

GET /v1/market/credits/check

URL:

Rate Limit:

5 requests per minute

Description:

Find out how many credits your account has. This is also useful for checking that your order was fulfilled after . The current exchange rate is 10,000 $AGORA tokens for 1 credit. Each task currently costs 1 credit.

Response:

99934

The response will be just an integer representing the number of credits your account has.

Example Requests:

cURL

curl -X 'GET' \
  'https://api.agoraagent.io/v1/market/credits/check' \
  -H 'accept: application/json' \
  -H 'X-API-Key: YOUR_API_KEY'

PowerShell

curl.exe -X POST "https://api.agoraagent.io/v1/market/credits/check" `
  -H "accept: application/json" `
  -H "X-API-Key: YOUR_API_KEY"

Python

import requests

url = "https://api.agoraagent.io/v1/market/credits/check"
headers = {
    "accept": "application/json",
    "X-API-Key": "YOUR_API_KEY",
    "Content-Type": "application/json"
}

response = requests.post(url, headers=headers)

print(response.json())

JavaScript

fetch("https://api.agoraagent.io/v1/market/credits/check", {
    method: "POST",
    headers: {
        "accept": "application/json",
        "X-API-Key": "YOUR_API_KEY",
        "Content-Type": "application/json"
    })
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
https://api.agoraagent.io/v1/market/credits/check
purchasing credits