getSendBlockList

Prev Next

Classic/VPC環境で利用できます。

特定の受信者に対して、システムで自動的に送信を遮断する基本時間を照会します。

リクエスト

リクエスト形式を説明します。リクエスト形式は次の通りです。

メソッド URI
GET /send-block

リクエストヘッダ

Cloud Outbound Mailer APIで共通して使用されるヘッダの詳細は、Cloud Outbound Mailerのリクエストヘッダをご参照ください。

リクエストクエリパラメータ

パラメータの説明は次の通りです。

フィールド タイプ 必須の有無 説明
size Integer Optional ページごとのレコード数
  • 10 (デフォルト)
page Integer Optional 照会対象のページインデックス
  • 0以上
sort String Optional ソート基準
  • createUtc (デフォルト)
    • createUtc: 作成日時
  • property(,asc|desc)形式
    • asc (デフォルト)
  • 複数のソート基準を設定可能
targetAddress String Required 送信遮断内訳を確認する受信者のメールアドレス

リクエスト例

リクエストのサンプルコードは次の通りです。

curl --location --request GET 'https://mail.apigw.ntruss.com/api/v1/send-block
?targetAddress=test01%40ncp-mail.com'
--header 'x-ncp-apigw-timestamp: {Timestamp}'
--header 'x-ncp-iam-access-key: {Access Key}'
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}'

レスポンス

レスポンス形式を説明します。

レスポンスボディ

レスポンスボディの説明は次の通りです。

フィールド タイプ 必須の有無 説明
content List<SendBlockHistoryResponse> Optional 送信遮断リストの詳細
registerStatus String Required そのメールが現在送信遮断されているかどうか
expectedDeleteDate NesDateTime Required 遮断解除が予定されている日時
last Boolean Required 最後のページであるか否か
totalElements Integer Required 総レコード数
totalPages Integer Required 総ページ数
first Boolean Required 最初のページなのか否か
numberOfElements Integer Required 現在ページのレコード数
size Integer Required ページごとのレコード数
number Integer Required 現在ページのインデックス
  • 0以上
sort List<Sort> Required ソート基準

レスポンスステータスコード

レスポンスステータスコードの説明は次の通りです。

HTTPステータスコード コード 説明
200 - リクエスト成功
400 - 認証失敗、無効なリクエスト
400 77101 ログイン情報エラー
400 77102 リクエストエラー
400 77103 リクエストしたリソースが存在しない
403 77201 リクエストしたリソースに対する権限がない
403 77202 メールサービスの使用を申し込んでいないユーザーが呼び出した場合
405 77001 サポートしないメソッドタイプ
415 77002 サポートしないメディアタイプ
500 - サーバエラー
500 77301 基本プロジェクトが存在しない
500 77302 外部システム API連携エラー
500 77303 その他の内部サーバエラー

レスポンス例

レスポンスのサンプルコードは次の通りです。

{
  "content": [
    {
      "targetAddress": "test01@ncp-mail.com",
      "actionType": {
        "label": "Delete",
        "code": "D"
      },
      "actionRequesterType": {
        "label": "System",
        "code": "SYSTEM"
      },
      "requestDate": {
        "utc": 1593076560930,
        "formattedDate": "2020-06-25",
        "formattedDateTime": "2020-06-25 18:16:00 930"
      },
      "historySid": 62633,
      "sendResultCode": null,
      "sendResultMessage": null
    },
    {
      "targetAddress": "test01@ncp-mail.com",
      "actionType": {
        "label": "Create",
        "code": "C"
      },
      "actionRequesterType": {
        "label": "Other customer",
        "code": "OTHER_CUSTOMER"
      },
      "requestDate": {
        "utc": 1592471705229,
        "formattedDate": "2020-06-18",
        "formattedDateTime": "2020-06-18 18:15:05 229"
      },
      "historySid": 62632,
      "sendResultCode": "RECIPIENT_ADDRESS_ERROR",
      "sendResultMessage": "550 5.1.1 <test01@ncp-mail.com>: Recipient address rejected: User unknown in local recipient table\n"
    }
  ],
  "registerStatus": "Not blocked",
  "expectedDeleteDate": null,
  "last": true,
  "totalElements": 8,
  "totalPages": 1,
  "first": true,
  "numberOfElements": 8,
  "size": 10,
  "number": 0,
  "sort": [
    {
      "direction": "DESC",
      "property": "createUtc",
      "ignoreCase": false,
      "nullHandling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ]
}