Subaccount info

GET
https://www.digicert.com/services/v2/account/subaccount/{{subaccount_id}}

Use this endpoint to get info about a subaccount.

cURL
curl -X GET \
  'https://www.digicert.com/services/v2/account/subaccount/{{subaccount_id}}' \
  -H 'Content-Type: application/json' \
  -H 'X-DC-DEVKEY: {{api_key}}'
Python
import requests

url = "https://www.digicert.com/services/v2/account/subaccount/{{subaccount_id}}"

payload = ""
headers = {
    'X-DC-DEVKEY': "{{api_key}}",
    'Content-Type': "application/json"
    }

response = requests.request("GET", url, data=payload, headers=headers)

print(response.text)
Go
package main

import (
	"fmt"
	"net/http"
	"io/ioutil"
)

func main() {

	url := "https://www.digicert.com/services/v2/account/subaccount/{{subaccount_id}}"

	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))

}
NodeJS
var request = require("request");

var options = { method: 'GET',
  url: 'https://www.digicert.com/services/v2/account/subaccount/{{subaccount_id}}',
  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);
});
200 OK
{
  "account_id": 1122339,
  "account_type": "reseller",
  "organization_name": "Real Organization",
  "date_created": "2018-11-29 18:25:04",
  "parent_account_id": "1122331",
  "billing_account_name": "Billing Account, Inc.",
  "billing_account_id": 1122328,
  "account_manager": "Jim James",
  "bill_parent": false,
  "master_user": {
    "first_name": "Alan",
    "last_name": "Allen",
    "email": "alan.allen@example.com",
    "job_title": "subreseller",
    "telephone": "801-701-9600",
    "i18n_language_id": "1",
    "container_id": "11223"
  },
  "organization": {
    "id": 121212,
    "status": "active",
    "name": "Real Organization",
    "address": "123 Fake Street",
    "zip": "84043",
    "city": "Lehi",
    "state": "ut",
    "country": "us",
    "telephone": "801-701-9600",
    "is_active": true,
    "container": {
      "id": 11223,
      "parent_id": 0,
      "name": "Real Organization",
      "is_active": true
    }
  },
  "billing_contact": {
    "name": "Alan Allen",
    "address": "123 Fake Street",
    "city": "Lehi",
    "state": "ut",
    "zip": "84043",
    "country": "us",
    "email": "alan.allen@example.com",
    "phone": "801-701-9600"
  }
}
Name Type Description
account_id int Subaccount ID.
account_type string Defines the subaccount type.
See Glossary – Subaccount types
organization_name string Legal name of the subaccount's primary organization.
date_created string Timestamp of when the subaccount was created.
Format: yyyy-MM-dd HH:mm:ss
parent_account_id string Account ID of the subaccount's parent.
billing_account_name string Name of the parent account used for billing.
billing_account_id int Account ID of the parent account used for billing.
account_manager string Name of the subaccount's account representative.
bill_parent bool Specifies if parent account is billed for certificate orders.
master_user object Details about the subaccount administrator.
.. first_name string First name of the subaccount administrator.
.. last_name string Last name of the subaccount administrator.
.. email string Email address of the subaccount administrator.
.. job_title string Job title of the subaccount administrator.
.. telephone string Telephone number of the subaccount administrator.
.. i18n_language_id string Preferred language for the subaccount administrator.
.. container_id string Container ID the subaccount administrator is assigned to.
organization object Details about the subaccount's primary organization.
.. id int Organization ID.
.. status string Organization status.
Possible values: active, inactive
.. name string Legal name of the organization.
.. address string Address of the organization.
.. zip string Postal code of the organization.
.. city string City where the organization is located.
.. state string State where the organization is located.
.. country string Country where the organization is located.
.. telephone string Organization telephone number.
.. is_active bool Active status of the organization.
.. container object Primary container the organization is attached to.
.. .. id int Container ID.
.. .. parent_id int ID of the container's parent.
.. .. name string Name of the container.
.. .. is_active bool Active status of the container.
billing_contact object Details about the subaccount's billing contact.
.. name string
.. address string
.. city string
.. state string
.. zip string
.. country string
.. email string
.. phone string