View balance
2 minute read
GET
Use this endpoint to view the current balance of your account.https://www.digicert.com/services/v2/finance/balance
Example requests and responses
curl -X GET \
https://www.digicert.com/services/v2/finance/balance \
-H 'Content-Type: application/json' \
-H 'X-DC-DEVKEY: {{api_key}}'import requests
url = "https://www.digicert.com/services/v2/finance/balance"
payload = ""
headers = {
'X-DC-DEVKEY': "{{api_key}}",
'Content-Type': "application/json"
}
response = requests.request("GET", url, data=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://www.digicert.com/services/v2/finance/balance"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-DC-DEVKEY", "{{api_key}}")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}var request = require("request");
var options = { method: 'GET',
url: 'https://www.digicert.com/services/v2/finance/balance',
headers:
{ 'Content-Type': 'application/json',
'X-DC-DEVKEY': '{{api_key}}' } };
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});{
"balance": "454.00",
"currency": "USD",
"unpaid_invoice_balance": "0.00",
"negative_balance_limit": "2000.00",
"used_credit_from_other_containers": "0.00",
"total_available_funds": "2454.00"
}{
"balance": "-1000.70",
"currency": "USD",
"unpaid_invoice_balance": "0.00",
"used_credit_from_other_containers": "0.00",
"unlimited_negative_balance": true
}URL query strings
Important
Thecontainer_id URL query string is required if your account contains more than one division.| Name | Req/Opt | Type | Description |
|---|---|---|---|
| container_id | optional | int | Filter results to the specified container. |
Response parameters
| Name | Type | Description |
|---|---|---|
| balance | string | Current account balance. |
| currency | string | Currency code for monetary values in this response. Possible values: See Glossary - DigiCert currencies |
| unpaid_invoice_balance | string | Amount owed for unpaid invoices. |
| negative_balance_limit | string | Amount the account balance can go into the negative. Not returned if unlimited_negative_balance is true. |
| total_available_funds | string | Total funds available for future purchases charged to the account balance. Calculated as balance + negative_balance_limit - unpaid_invoice_balance - used_credit_from_other_containers. Not returned if unlimited_negative_balance is true. |
| used_credit_from_other_containers | string | Total amount owed by other divisions in the account, for accounts with separate division funds enabled. |
| unlimited_negative_balance | boolean | If true, the account has no negative balance limit. Not returned if false. |
Was this page helpful?
Provide feedback