Über die API kannst du laufende und abgeschlossene Aufträge ansehen und verwalten.

Inhaltsverzeichnis dieser Seite

Grundlagen der JSON-und XML-API

Alle wichtigen Informationen für die Nutzung der JSON- und XML-API findest du bei den API-Grundlagen,  den XML- und JSON-Grundlagen.
Die spezifischen SSL-Objekte sind hier dokumentiert, die SSL-Auftragstypen hier.

Laufende und abgeschlossene Aufträge auflisten

Mit einer Listenabfrage kannst du über die JSON- und die XML- API alle laufenden und abgeschlossenen Aufträge abfragen.

Request
POST /job/_search 
POST /job/history/_search
{
	"view": {
		"limit": 10,
        "offset": 0
    }
}
Response
{
  "stid": "20180926-stid",
  "status": {
    "code": "S300115",
    "text": "Auftragsdaten wurden erfolgreich ermittelt.",
    "type": "SUCCESS"
  },
  "object": {
    "type": "ObjectJob",
    "summary": 1
  },
  "data": [
    {
      "job": {
        "created": "2019-10-23T16:12:33.000+0200",
        "updated": "2019-10-23T17:26:01.000+0200",
        "owner": {
          "context": 9,
          "user": "user"
        },
        "updater": {
          "context": 9,
          "user": "user"
        },
        "status": "DEFFERED",
        "subStatus": "WF_EMAIL_AUTH",
        "execution": "2019-10-23T17:25:58.000+0200",
        "subType": "RAPID_SSL",
        "action": "create",
        "id": 12345
      },
      "object": {
        "type": "Certificate",
        "value": "domain.de"
      }
    }
  ]
}
Request
<task>
	<code>400115</code><!-- History 400135--> 
	<view>
		<limit>10</limit>
		<offset>0</offset>
	</view>
</task>
Response
<response>
	<result>
		<data>
			<summary>1</summary>
			<certificate_job>
				<job>
					<id>12345</id>
					<owner>
						<user>user</user>
						<context>9</context>
					</owner>
					<updater>
						<user>user</user>
						<context>9</context>
					</updater>
					<object>domain.de</object>
					<status>DEFFERED</status>
					<sub_status>WF_EMAIL_AUTH</sub_status>
					<created>2019-10-23 16:12:33</created>
					<updated>2019-10-23 17:26:01</updated>
					<type>ssl</type>
					<sub_type>RAPID_SSL</sub_type>
					<action>create</action>
					<execution>2019-10-23 17:25:58</execution>
				</job>
			</certificate_job>
		</data>
		<status>
			<code>S400115</code>
			<text>Zertifikats-Bestellungen wurden erfolgreich ermittelt.</text>
			<type>success</type>
		</status>
	</result>
	<stid>20200228-stid</stid>
</response>

Daten eines laufenden oder abgeschlossenen Auftrags anzeigen

Die API bietet die Möglichkeit sich Details für einen laufenden bzw. abgeschlossenen Auftrag anzeigen zu lassen. Darunter fallen zum Beispiel :

  • Daten für die Domain-Controll-Validation (DCV)
  • Status der Bestellung auf Seiten der CA
  • Die Zertifikatsdaten wie z. B. der verwendete CSR
Request
GET /job/{id}
GET /job/history/{id
Response
{
  "stid": "20200228-stid",
  "status": {
    "code": "S300114",
    "text": "Der Workflow-Auftrag wurde erfolgreich ermittelt.",
    "type": "SUCCESS"
  },
  "object": {
    "type": "ObjectJob",
    "value": "12345"
  },
  "data": [
    {
      "job": {
        "created": "2019-10-23T16:12:33.000+0200",
        "updated": "2019-10-23T17:26:01.000+0200",
        "owner": {
          "context": 9,
          "user": "user"
        },
        "updater": {
          "context": 9,
          "user": "user"
        },
        "status": "DEFFERED",
        "subStatus": "WF_EMAIL_AUTH",
        "execution": "2019-10-23T17:25:58.000+0200",
        "subType": "RAPID_SSL",
        "action": "create",
        "id": 12345
      },
      "object": {
        "type": "Certificate",
        "value": "domain.de",
        "data": {
          "created": "2019-10-23T00:00:00.000+0200",
          "partnerOrderId": "IX-CC-12345",
          "orderId": "9202720",
          "adminContact": {
            "fname": "Jon",
            "lname": "Doe",
            "phone": "+49-0-0",
            "fax": "+49-0-0",
            "email": "jon.doe@domain.de",
            "title": "Herr",
            "organization": "Muster GmbH",
            "address": [
              "Musterstrasse 6"
            ],
            "pcode": "12345",
            "city": "Musterstadt",
            "country": "DE",
            "state": "Bayern",
            "id": 1
          },
          "technicalContact": {
            "fname": "Jon",
            "lname": "Doe",
            "phone": "+49-0-0",
            "fax": "+49-0-0",
            "email": "jon.doe@domain.de",
            "title": "Herr",
            "organization": "Muster GmbH",
            "address": [
              "Musterstrasse 6"
            ],
            "pcode": "12345",
            "city": "Musterstadt",
            "country": "DE",
            "state": "Bayern",
            "id": 1
          },
          "name": "domain.de",
          "lifetime": {
            "unit": "MONTH",
            "period": 12
          },
          "software": "APACHE2",
          "csr": "-----BEGIN CERTIFICATE REQUEST-----\n ... \n-----END CERTIFICATE REQUEST-----",
          "product": "RAPID_SSL",
          "signatureHashAlgorithm": "SHA2_FULL_CHAIN",
          "expire": "2020-10-23T00:00:00.000+0200",
          "certificationAuthority": [],
          "authentication": {
            "method": "EMAIL",
            "approverEmails": [
              "admin@domain.de"
            ]
          },
          "certificateTransparencyPrivacy": "PUBLIC"
        }
      }
    }
  ]
}
Request
<request>
	<auth>
		<user>USER</user>
		<context>CONTEXT</context>
		<password>PASSWORD</password>
	</auth>
	<task>
		<code>400114</code>
		<certificate_job>
			<job>
				<id>12345</id>
			</job>
		</certificate_job>
	</task>
</request>
Response
<response>
	<result>
		<data>
			<certificate_job>
				<certificate>
					<partner_order_id>IX-CC-12345</partner_order_id>
					<order_id>9202720</order_id>
					<admin>
						<first>Jon</first>
						<last>Doe</last>
						<phone>+49-0-0</phone>
						<fax>+49-0-0</fax>
						<email>jon.doe@domain.de</email>
						<title>Herr</title>
						<organization>Muster GmbH</organization>
						<address>Musterstrasse 6</address>
						<postal_code>12345</postal_code>
						<city>Musterstadt</city>
						<country>DE</country>
						<state>Bayern</state>
						<id>1</id>
					</admin>
					<technical>
						<first>Jon</first>
						<last>Doe</last>
						<phone>+49-0-0</phone>
						<fax>+49-0-0</fax>
						<email>jon.doe@domain.de</email>
						<title>Herr</title>
						<organization>Muster GmbH</organization>
						<address>Musterstrasse 6</address>
						<postal_code>12345</postal_code>
						<city>Musterstadt</city>
						<country>DE</country>
						<state>Bayern</state>
						<id>1</id>
					</technical>
					<name>domain.de</name>
					<approver_email>admin@domain.de</approver_email>
					<lifetime>12</lifetime>
					<software>APACHE2</software>
					<csr><![CDATA[-----BEGIN CERTIFICATE REQUEST----- ... -----END CERTIFICATE REQUEST-----]]></csr>
					<product>RAPID_SSL</product>
					<sha>SHA2_FULL_CHAIN</sha>
					<expire>2020-10-23 00:00:00</expire>
					<extension/>
					<authentication>
						<method>EMAIL</method>
						<approver_email>admin@domain.de</approver_email>
					</authentication>
					<certificate_transparency_privacy>PUBLIC</certificate_transparency_privacy>
					<created>2019-10-23 00:00:00</created>
				</certificate>
				<job>
					<id>12345</id>
					<owner>
						<user>user</user>
						<context>9</context>
					</owner>
					<updater>
						<user>user</user>
						<context4>9</context>
					</updater>
					<object>domain.de</object>
					<status>DEFFERED</status>
					<sub_status>WF_EMAIL_AUTH</sub_status>
					<created>2019-10-23 16:12:33</created>
					<updated>2019-10-23 17:26:01</updated>
					<type>ssl</type>
					<sub_type>RAPID_SSL</sub_type>
					<action>create</action>
					<execution>2019-10-23 17:25:58</execution>
				</job>
			</certificate_job>
		</data>
		<status>
			<code>S400114</code>
			<text>Zertifikats-Bestellung wurde erfolgreich ermittelt.</text>
			<type>success</type>
			<object>
				<type>certificate_job</type>
				<value>4297755796</value>
			</object>
		</status>
	</result>
	<stid>20200228-stid</stid>
</response>

Laufenden Auftrag abbrechen

Laufende Aufträge können über die API abgebrochen werden, solange sie noch nicht den Status SUCCESS oder FAILED erreicht haben.
Beachte, dass der Abbruch eines laufenden Auftrags erst wirksam wird, wenn er bei der CA abgebrochen wurde. Davor wird für den Auftrags der Status CANCELED angezeigt.

Request
PUT /job/{id}/_cancel
Response
{
  "stid": "20200228-stid",
  "status": {
    "code": "S300121",
    "text": "Der Workflow-Auftrag wurde erfolgreich gekündigt.",
    "type": "SUCCESS"
  },
  "object": {
    "type": "ObjectJob",
    "value": "12345"
  }
}
Request
<request>
	<auth>
		<user>USER</user>
		<context>CONTEXT</context>
		<password>PASSWORD</password>
	</auth>
	<task>
		<code>400113</code>
		<certificate_job>
			<job>
				<id>12345</id>
			</job>
		</certificate_job>
	</task>
</request>
Response
<response>
	<result>
		<data/>
		<status>
			<code>S400113</code>
			<text>Zertifikats-Auftrag wurde erfolgreich abgebrochen.</text>
			<type>success</type>
			<object>
				<type>certificate_job</type>
				<value>4297782230</value>
			</object>
		</status>
	</result>
	<stid>20200228-stid</stid>
</response>

Validierungs-E-Mail neu versenden

Die Validierungs-E-Mail kann über die Route POST /job/{id}/_resendApproverEmail bzw. den Task-Code 400118 erneut versendet werden.

Request
POST /job/{id}/_resendApproverEmail
Response
{
  "stid": "20200228-stid",
  "status": {
    "code": "S400118",
    "text": "Der Auftrag zum erneuten Versenden wurde erfolgreich an die CA übermittelt.",
    "type": "SUCCESS"
  },
  "object": {
    "type": "Certificate_job",
    "value": "12345"
  }
}
Request
<request>
	<auth>
		<user>USER</user>
		<context>CONTEXT</context>
		<password>PASSWORD</password>
	</auth>
	<task>
		<code>400118</code>
		<certificate_job>
			<job>
				<id>12345</id>
			</job>
		</certificate_job>
	</task>
</request>
Response
<response>
	<result>
		<data/>
		<status>
			<code>S400118</code>
			<text>Der Auftrag zum erneuten Versenden wurde erfolgreich an die CA übermittel</text>
			<type>success</type>
			<object>
				<type>certificate_job</type>
				<value>12345</value>
			</object>
		</status>
	</result>
	<stid>20200228-stid</stid>
</response>