Fetch Credit Balance API

Get current credit balance through API.

Fetch Credit Balance API Call Smaple Code

curl -X GET --header 'Accept: application/json' \
  --header 'APIKEY: INSERT_YOUR_API_KEY_HERE' \
  'https://www.cutout.pro/api/v1/mySubscription'
import requests
url = 'https://www.cutout.pro/api/v1/mySubscription'
response = requests.get(
url,
headers={'APIKEY': apikey},
)
content = response.content.decode(encoding="utf-8")
print(content)
  @Autowired
private RestTemplate restTemplate;


HttpHeaders headers = new HttpHeaders();
headers.add("APIKEY","INSERT_YOUR_API_KEY_HERE");
HttpEntity request = new HttpEntity(headers);
RequestCallback requestCallback = restTemplate.httpEntityCallback(request, Resource.class);
ResponseExtractor<ResponseEntity<JSONObject>> responseExtractor = restTemplate.responseEntityExtractor(JSONObject.class);
String apiUrl = "https://www.cutout.pro/api/v1/mySubscription";
ResponseEntity<JSONObject> response = restTemplate.execute(apiUrl, HttpMethod.GET, requestCallback, responseExtractor);
System.out.println(response.getBody().toJSONString());

API documentation

Request description

(1) Request parameters (Header)

parameterparameter typevalue
Content-Typestringapplication/json;charset=UTF-8
APIKEYstringYour API Key

Return description

  • Return parameter: Return json format data
{
  "code": 0,
  "data": {
    //Remaining amount of monthly subscription
    "monthBalance": 0,
    //Remaining credits for pay-as-you-go plans
    "imageBalance": 0,
    //Remaining time for video background removal
    "videoBalance": 0,
    //Monthly subscription start date
    "monthStartDate": "2020-01-01 00:00:00",
    //Monthly subscription expiration date
    "monthExpireDate": "2021-01-01 00:00:00"
  },
  "msg": null,
  "time": 1618482003879
}