The caller's credit balance (CR1)
curl --request GET \
--url https://api.eddy.engineer/v1/creditsimport requests
url = "https://api.eddy.engineer/v1/credits"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.eddy.engineer/v1/credits', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.eddy.engineer/v1/credits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.eddy.engineer/v1/credits"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.eddy.engineer/v1/credits")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eddy.engineer/v1/credits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"account": "<string>",
"available": 123,
"available_millicredits": 123,
"debt_millicredits": 123,
"grants": [
{}
],
"held_millicredits": 123,
"holds": [
{}
]
}Meta
The caller's credit balance (CR1)
The balance of the caller's billing account — the org they are acting in: available (spendable grants − open holds − debt), held, debt, each grant with its remainder and expiry, the open holds, lifetime totals; in credits (1 credit = US$0.01) and integer millicredits. The ledger is append-only and lives on ParamDB (ledger/<org>). CR3: also the billing mode (`billing`: off / record / enforce) and the metered usage not yet posted (`pending_microcredits`).
GET
/
v1
/
credits
The caller's credit balance (CR1)
curl --request GET \
--url https://api.eddy.engineer/v1/creditsimport requests
url = "https://api.eddy.engineer/v1/credits"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.eddy.engineer/v1/credits', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.eddy.engineer/v1/credits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.eddy.engineer/v1/credits"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.eddy.engineer/v1/credits")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eddy.engineer/v1/credits")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"account": "<string>",
"available": 123,
"available_millicredits": 123,
"debt_millicredits": 123,
"grants": [
{}
],
"held_millicredits": 123,
"holds": [
{}
]
}