コールドメールAPI
メールを却下する
承認待ちのメールを送らず、その人たちのシーケンスを終えます。無料。
承認待ち、または承認済みでまだ送られていないメールを却下します。メールは送られず(skipped)、その受信者にはキャンペーンからもう何も届きません(stopped、理由はdeclined)。代わりに別の内容を送るには、PATCH /email/messages/{id}でメールを変更してください。承認を求めるように設定したキーは却下できません(forbidden)。無料です。
- 課金: 無料。
テストキー(won_test_...)では、これはサンドボックスで動きます。何も送信されず、課金もされません。
POST
apiKeyheader
AuthorizationBearer <APIキー>Authorization: Bearer won_live_..., a key from the console.
Idempotency-Key?stringAny unique string. A retry with the same key and the same body returns the first response and is not charged again.
長さ
length <= 255application/json- body
message_ids*array<>Up to 100 email IDs, such as msg_3e5r4k2m9x7p1q8w, from GET /email/messages?status=pending_approval.
要素
1 <= items <= 100The result.
application/json- response
data*array<>One result per ID, in the order given.
notice*|A plain sentence when there is something to know about this answer. Null otherwise.
usage*Nothing is charged here. The balance, for reference.
curl -X POST 'https://api.won.dev/v1/email/messages/decline' \ -H 'Content-Type: application/json' \ -d '{ "message_ids": [ "msg_3e5r4k2m9x7p1q8w" ]}'レスポンスの例
{ "data": [ { "id": "msg_3e5r4k2m9x7p1q8w", "done": true, "status": "skipped" } ], "notice": null, "usage": { "cost": 0, "balance": 48.08, "replayed": false }}最終更新日