このエンドポイントを使用して、お使いのアカウントのすべてのカスタムオーダーフィールド用のメタデータを一覧表示します。
curl -X GET \
https://www.digicert.com/services/v2/account/metadata \
-H 'Content-Type: application/json' \
-H 'X-DC-DEVKEY: {{api_key}}'
import requests
url = "https://www.digicert.com/services/v2/account/metadata"
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/account/metadata"
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/account/metadata',
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);
});
{
"metadata": [
{
"id": 112,
"label": "Additional emails",
"is_required": false,
"is_active": true,
"data_type": "email_list"
},
{
"id": 113,
"label": "Jira URL",
"is_required": false,
"is_active": true,
},
{
"id": 114,
"label": "For department",
"is_required": true,
"is_active": true,
"data_type": "text"
},
{
"id": 115,
"label": "Invoice #",
"is_required": true,
"is_active": true,
"data_type": "int"
},
{
"id": 116,
"label": "SRE contact",
"is_required": false,
"is_active": false,
"data_type": "email_address"
}
]
}
名前 | 種別 | 説明 |
---|---|---|
metadata | array | 返されたカスタムオーダーフィールドオブジェクトのリスト。 |
.. id | int | カスタムオーダーフィールド ID |
.. label | string |
カスタムオーダーフィールドの名前 この名前は、オーダーフォーム上のフィールド上に表示されます。 |
.. is_required | bool | フィールドが必要な場合に指定します。 |
.. is_active | bool | フィールドがオーダーフォーム上に表示される場合に指定します。 |
.. data_type | string |
カスタマーオーダーフィールド用の入力タイプ 未記入の場合は、これは 他の入力タイプを示します。 「用語集 — カスタムオーダーフィールド入力タイプ」を参照してください |