IPQS
Credit Usage API

About the Credit Usage API

You can use the Credit Usage API to access your account's total number of available credits and current usage for this billing period. This data can help you track your usage patterns and make informed decisions about credit usage.

API Request URLs

JSON

https://www.ipqualityscore.com/api/json/account/YOUR_API_KEY_HERE

XML

https://www.ipqualityscore.com/api/xml/account/YOUR_API_KEY_HERE

Example Response

This is an example success response in JSON format. Responses are also available in XML format.

{
	"success":true,
	"message":"Success",
	"credits":3004522,
	"usage":478,
	"proxy_usage":6,
	"email_usage":472,
	"mobile_sdk_usage": 22,
	"phone_usage": 1231,
	"url_usage": 211,
	"fingerprint_usage":0,
	"request_id":"3ift1XN"
}
// You API Key.
$key = 'YOUR_API_KEY_HERE';

// Base URL
$url = 'https://www.ipqualityscore.com/api/json/account/%s';
	

// Finish assembling the URL and make the request.
$json = file_get_contents(sprintf($url, $key));

// Decode json and print the number of available credits.
$result = json_decode($json, true);
if(isset($result['success']) && $result['success'] === true){
	echo "Available credits: ".$result['credits'];
} else {
	echo $result['message'];	
}
import json
import requests

# You may need to install Requests pip
# python -m pip install requests

class IPQS:
    key = "YOUR_API_KEY_HERE"
    def usage_api(self)->dict:
        url = 'https://www.ipqualityscore.com/api/json/account/%s' % (self.key)
        x = requests.get(url)

        return (json.loads(x.text))

if __name__ == "__main__":
    result = (IPQS()).usage_api()
    if 'success' in result and result['success'] == True:
        print('Available credits: %s' %(result['credits']))
    else:
        print(result['message'])

Ready to eliminate fraud?

Start fighting fraud now with 1,000 Free Lookups!

We're happy to answer any questions or concerns.

Chat with our fraud detection experts any day of the week.

Call us at: (800) 713-2618