我只需要验证发送域和API密钥。现在我用这个卷曲:
curl \
-H "Content-Type: application/json" \
-H "Authorization: <REPLACE_WITH_YOUR_API_KEY>" \
-X POST -d '{"options":{"open_tracking":true,"click_tracking":true},"metadata":{"some_useful_metadata":"testing_sparkpost"},"substitution_data":{"signature":"<REPLACE_WITH_YOUR_FIRST_AND_LAST_NAME>"},"recipients":[{"address":{"email":"<REPLACE_WITH_YOUR_EMAIL_ADDRESS>"},"tags":["learning"],"substitution_data":{"customer_type":"Platinum","first_name":"<REPLACE_WITH_YOUR_FIRST_NAME>"}}],"content":{"from":{"name":"Awesome Company","email":"testing@<REPLACE_WITH_YOUR_SENDING_DOMAIN>"},"subject":"My first SparkPost Transmission","text":"Hi {{first_name}}\r\nYou have just sent your first email through SparkPost!\r\nCongratulations,\r\n{{signature}}","html":"<strong>Hi {{first_name}},</strong><p>You have just sent your first email through SparkPost!</p><p>Congratulations!</p>{{signature}}"}}' \
https://api.sparkpost.com/api/v1/transmissions
此网址向我发送了一封电子邮件,因此它是正确的,但我必须使用不会发送电子邮件的网址,但要验证API密钥和发送域的正确性。有人可以帮帮我吗?
答案 0 :(得分:0)
听起来你想验证两件事:
为此,您可以使用与问题中相同的cURL命令,但将 div.different {
transform: rotate(0deg) translate(1000px,400px);
border-style: solid;
padding: 25px;
background-color: yellow;
display: block;
width: 125px;
transition:1s ease-in-out;
transform-origin: 1000px 400px;
}
div.different:hover{
background-color: red;
-webkit-transform: rotate(300deg) translate(1000px,400px);
}
附加到域的末尾。如果您的API密钥和发送域正确但不会发送电子邮件(但是该发送仍然会计入您的使用情况),那么将返回200。您可以阅读有关下沉洞here的更多信息。
或者,您可以使用the Sending Domains page或Sending Domains API查看您域名的状态。您可以使用the Credentials page验证您的API密钥是否具有“传输:读/写”权限